Permalink
Browse files

making sure to kill the authentication if the user is banned

  • Loading branch information...
1 parent afda156 commit 7e89138d65063fbac9334b130a266626a9049b36 erik committed Jul 9, 2012
Showing with 5 additions and 0 deletions.
  1. +5 −0 app/controllers/sessions_controller.rb
@@ -70,6 +70,11 @@ def create
if banned?
flash[:notice] = "Sorry, something seems to be wrong. Try again later."
+ self.current_user.forget_me if logged_in?
+ delete_cookie :auth_token
+ delete_cookie :balance_text
+ delete_cookie :current_user_full_name
+ reset_session
redirect_back_or_default('/')
return
elsif logged_in?

0 comments on commit 7e89138

Please sign in to comment.