FIX: fixed the bug to not to save a map if the filename already exists