Added by Archie Con over 13 years ago
My problem is i my plugin to be accessed only by logger
users, so i use :if symbol in my init.rb file of my
plugin .The result i cannot start my application anymore.
Here is my init.rb:
menu :account_menu , :teams, {:controller => 'teams', :action => 'index' }, :caption => 'Teams_register', :if => User.current.logged?
Archie Con wrote:
[...]
You must past a Proc
to the :if
parameter. Something like :if => Proc.new { User.current.logged? }
should do.