Salome HOME
Fix for the issue #2819 : Fatal error when undo
[modules/shaper.git] / src / Model / Model_AttributeRefList.cpp
index 7ffe0c4d38333c3e13ff49358c54272873fc3588..23849b7c53dfa60d0da454a10e0db392476377e5 100644 (file)
@@ -315,8 +315,9 @@ void Model_AttributeRefList::reinit()
 
 void Model_AttributeRefList::createHash()
 {
-  if (myHashUsed)
+  if (myHashUsed) {
     return;
+  }
   eraseHash();
   std::shared_ptr<Model_Document> aDoc = std::dynamic_pointer_cast<Model_Document>(
     owner()->document());
@@ -331,8 +332,6 @@ void Model_AttributeRefList::createHash()
         myHashObjects.insert(anObj);
       }
     }
-    if (!myHashObjects.empty()) // on open document with multi-rotation referenced have no results
-      myHashUsed = true;
   }
 }