Added flash messages support to controllers.