Update AttachImage.php

Check uploaded file format by mime type (fileinfo extension)