Merge pull request #15209 from firefly2442/StringBooleanProblem

prevent strings from being evaluated to just "true"
This commit is contained in:
Noshyaar 2017-12-31 12:35:39 +07:00 committed by GitHub
commit 16158d8db7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -3213,7 +3213,7 @@ bool SpatialEditorViewport::can_drop_data_fw(const Point2 &p_point, const Varian
continue;
}
memdelete(instanced_scene);
} else if (type == "Mesh" || "ArrayMesh" || "PrimitiveMesh") {
} else if (type == "Mesh" || type == "ArrayMesh" || type == "PrimitiveMesh") {
Ref<Mesh> mesh = ResourceLoader::load(files[i]);
if (!mesh.is_valid()) {
continue;