I’m having an odd problem… in application.rb I have:
helper_method :admin?
…since I use this all the time in my views to test if the user is an
administrator, of course. Pretty standard.
I thought I’d be able to use this in specific helpers, but I’m getting
“method not found”:
undefined method `admin?’
I’m surprised the admin? method works in a view but not in the
respective helper. Anything I’m missing? How can I use this method in
helpers?
Thanks!