maybe we could extract flash messages to some helper and use it in all places where needed? I think that I saw similar block of code in other views.