mattvanhorn/BJJLife

View on GitHub
app/controllers/admin/base_controller.rb

Summary

Maintainability
A
0 mins
Test Coverage
class Admin::BaseController < ApplicationController
  skip_before_filter :locate_user
  before_filter :authenticate

  protected

  def authenticate
    authenticate_or_request_with_http_basic do |username, password|
      username == ENV['ADMIN_USERNAME'] && password == ENV['ADMIN_PASSWORD']
    end
  end

end