added verification of file uploads (images only)