File upload modified and file upload bug fixed