In the documentation of cancan it shows how to fetch all accessible records (in http://wiki.github.com/ryanb/cancan/fetching-records) in this way:
@articles = Article.accessible_by(current_ability)
but what is current_ability? I've tried passing the current user which I'm using for authentication and authorization, but I've got this error:
NoMethodError: undefined method `conditions' for #<User:0x1092a3b90>
Any ideas what should I pass to accessible_by or what's wrong here?