0

I'm trying to remove a flash message and I'm using devise for the user management. Setting the value to null or an empty string just throws an error in the notice, removing it from the devise.en.yml gives a similar error.

Removing the notice from erb file isn't an option, I just want it to not display at all. Anyone got any ideas?

Synthesezia
  • 291
  • 2
  • 12

1 Answers1

3

You could call flash.discard(:notice) in an after filter of the controller. That should clear the flash message.

StefanS
  • 876
  • 1
  • 12
  • 21