refactored alerts handling : set up proper flash messages middleware(s)