fix removal of remote file
replate file() with preferable open()