I'm trying to figure out how to define cancancan abilities in my rails 4 app.
I use devise for authentication.
When I try:
if user_signed_in?
can :crud, Profile, :user_id => user.id #[for themselves]
I get an error that says:
undefined method `user_signed_in?' for #<Ability:0x007fd01b6d2fc0>
I thought devise had a helper called user_signed_in?
I don't understand this error at all. Can anyone see what I have done wrong?