Styled the flash messages and added better flash looping code