Added some localization
This commit is contained in:
@@ -10,7 +10,7 @@ class Ability
|
||||
can :read, Forum, :state => true, :category => { :state => true }
|
||||
can :read, Topic, :forum => { :state => true, :category => { :state => true } }
|
||||
can :read, Post, :topic => { :forum => { :state => true, :category => { :state => true } } }
|
||||
|
||||
|
||||
can :update, Post, :user_id => user.id, :topic => { :locked => false }
|
||||
can :destroy, [Topic,Post], :user_id => user.id, :topic => { :locked => false }
|
||||
|
||||
|
||||
@@ -16,6 +16,6 @@ class User < ActiveRecord::Base
|
||||
has_many :posts, :dependent => :destroy
|
||||
|
||||
def admin?
|
||||
true if self.username == 'admin'
|
||||
self.is_admin
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user