Sha256: 01ed870c9df0e72b9031ba1d0794cdd7061daa7806553ca847f92b55c0c91070

Contents?: true

Size: 389 Bytes

Versions: 3

Compression:

Stored size: 389 Bytes

Contents

class ApplicationController < ActionController::Base
  protect_from_forgery

  def login_required
    if current_user.blank?
      respond_to do |format|
        format.html  {
          authenticate_user!
        }
        format.js{
          render :partial => "common/not_logined"
        }
        format.all {
          head(:unauthorized)
        }
      end
    end
  
  end


end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
bootstrappers-0.2.1 templates/application_controller_rb
bootstrappers-0.2.0.1 templates/application_controller_rb
bootstrappers-0.2.0 templates/application_controller_rb