Fix for deleting files