Fixed extracting of the file name