From ac3c6b8520cbc6934b0542eda174036ea6bff113 Mon Sep 17 00:00:00 2001 From: Alexander Slesarenko Date: Fri, 25 Aug 2023 11:57:16 +0200 Subject: [PATCH] tx-signing-js: rollback changes in MapSigmaValidationSettings --- .../ergoplatform/validation/SigmaValidationSettings.scala | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/interpreter/shared/src/main/scala/org/ergoplatform/validation/SigmaValidationSettings.scala b/interpreter/shared/src/main/scala/org/ergoplatform/validation/SigmaValidationSettings.scala index fac738ce5a..e59575a272 100644 --- a/interpreter/shared/src/main/scala/org/ergoplatform/validation/SigmaValidationSettings.scala +++ b/interpreter/shared/src/main/scala/org/ergoplatform/validation/SigmaValidationSettings.scala @@ -72,12 +72,10 @@ sealed class MapSigmaValidationSettings(private val map: Map[Short, (ValidationR } override def equals(obj: Any): Boolean = (this eq obj.asInstanceOf[AnyRef]) || (obj match { - case that: MapSigmaValidationSettings => - map.size == that.map.size && - map.iterator.forall { case (id, v) => that.map.get(id).exists(_ == v) } + case that: MapSigmaValidationSettings => map == that.map case _ => false }) - override def hashCode(): Int = map.toIndexedSeq.sortBy(_._1).hashCode() + override def hashCode(): Int = map.hashCode() }