fix
This commit is contained in:
parent
fb650c6c9c
commit
278a89f57e
|
@ -28,7 +28,7 @@ class Admin::BoxController < ApplicationController
|
|||
private
|
||||
def check_login
|
||||
user = current_user
|
||||
if user.nil? || user.is_admin?
|
||||
if user.nil? || !user.is_admin?
|
||||
return render :file => "#{Rails.root}/app/views/errors/404.html", :layout => false, :status => :not_found, :formats => [:html]
|
||||
end
|
||||
end
|
||||
|
|
|
@ -60,7 +60,7 @@ class Admin::PlowController < ApplicationController
|
|||
private
|
||||
def check_login
|
||||
user = current_user
|
||||
if user.nil? || user.is_admin?
|
||||
if user.nil? || !user.is_admin?
|
||||
return render :file => "#{Rails.root}/app/views/errors/404.html", :layout => false, :status => :not_found, :formats => [:html]
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue