From f1b1a7022d7dc67d012d8891bc4c23c2652c825e Mon Sep 17 00:00:00 2001 From: "Dylan K. Taylor" Date: Thu, 17 Oct 2024 20:55:12 +0100 Subject: [PATCH] and a sanity check just in case --- tools/generate-blockstate-upgrade-schema.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/generate-blockstate-upgrade-schema.php b/tools/generate-blockstate-upgrade-schema.php index e5eab822f17..741098f7aa1 100644 --- a/tools/generate-blockstate-upgrade-schema.php +++ b/tools/generate-blockstate-upgrade-schema.php @@ -513,7 +513,11 @@ function processRemappedStates(array $upgradeTable) : array{ } } - $list[encodeOrderedProperties($oldState)] = new BlockStateUpgradeSchemaBlockRemap( + $fallbackRawFilter = encodeOrderedProperties($oldState); + if(isset($list[$fallbackRawFilter])){ + throw new AssumptionFailedError("Exact match filter collision for \"" . $pair->old->getName() . "\" - this should never happen"); + } + $list[$fallbackRawFilter] = new BlockStateUpgradeSchemaBlockRemap( $oldState, $newName, $cleanedNewState2,