added image files and error message and before filters