Added sessions controller and fixed flash messages