I’m a little perplexed why this isn’t working:
user = User.find(session[:user])
if user.level == 100
flash[:notice] = “welcome, admin”
flash[:notice] = “ha ha”
redirect_to :controller =>“account”, :action
flash[:notice] = “You are not an admin!!”
The first part (when user.level == 100) is ok but in the 2nd part it
goes directly to account/signup without displaying either flash message.
I’ve tried putting it before the redirect, after the redirect, both,
What’d I miss?