Changed the 'invalid picture type' error handling