diff options
Diffstat (limited to 'src/imports')
-rw-r--r-- | src/imports/testlib/TestCase.qml | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/imports/testlib/TestCase.qml b/src/imports/testlib/TestCase.qml index ad7533c550..1ead2f21b7 100644 --- a/src/imports/testlib/TestCase.qml +++ b/src/imports/testlib/TestCase.qml @@ -614,7 +614,8 @@ Item { function qtest_destroyTemporaryObjects() { for (var i = 0; i < qtest_temporaryObjects.length; ++i) { var temporaryObject = qtest_temporaryObjects[i]; - if (temporaryObject) + // ### the typeof check can be removed when QTBUG-57749 is fixed + if (temporaryObject && typeof temporaryObject.destroy === "function") temporaryObject.destroy(); } qtest_temporaryObjects = []; |