RailsCasts Pro episodes are now free!
Learn more or hide this
GitHub User: leandromoreira
If you face the problem with mongoid problem:
MONGO MOP Can't canonicalize query: BadValue unknown operator: $oid
Make sure you change current_user method:
- @current_user ||= User.find(session[:user_id]) if session[:user_id]
+ @current_user ||= User.find(session[:user_id]["$oid"]) if session[:user_id]
I would like to know (links) how to keep user logged in info inside cookies safety.
If I would opt by using an external table (properties -> name, value); how it would looks like?
I think the models could be something like this.
But, what are the best way to bind this to the view?
Perfect, I was using Simple Form then I had to use a different css path for that.