Fixed problem with  wrong path when uploading files.