Sha256: 423a0eba3f0bd55553f326b1d3c5da11de3e0116da460aba2e1214f154c01070

Contents?: true

Size: 227 Bytes

Versions: 5

Compression:

Stored size: 227 Bytes

Contents

class FlyAdmin::ApplicationController < ApplicationController
  before_filter :authenticate_admin!

  def authenticate_admin!
    unless current_user && current_user.admin?
      redirect_to main_app.root_url
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
fly_admin-0.0.5 app/controllers/fly_admin/application_controller.rb
fly_admin-0.0.4 app/controllers/fly_admin/application_controller.rb
fly_admin-0.0.3 app/controllers/fly_admin/application_controller.rb
fly_admin-0.0.2 app/controllers/fly_admin/application_controller.rb
fly_admin-0.0.1 app/controllers/fly_admin/application_controller.rb