Răsfoiți Sursa

Merge pull request #5692 from shamazmazum/fix-assert

Fix incorrect assertion in CArtPlace::setArtifact
Ivan Savenko 5 luni în urmă
părinte
comite
e6c75dd66d
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      client/widgets/CComponentHolder.cpp

+ 1 - 1
client/widgets/CComponentHolder.cpp

@@ -117,7 +117,7 @@ void CArtPlace::setArtifact(const ArtifactID & newArtId, const SpellID & newSpel
 	if(artId == ArtifactID::SPELL_SCROLL)
 	{
 		spellId = newSpellId;
-		assert(spellId.num > 0);
+		assert(spellId != SpellID::NONE);
 
 		if(settings["general"]["enableUiEnhancements"].Bool())
 		{