fix existence check