From 0ea71c3e1d272e3701efb73ff3b2fc5adfa6990a Mon Sep 17 00:00:00 2001 From: Ryan Cramer Date: Fri, 22 Nov 2024 15:10:22 -0500 Subject: [PATCH] Fix issue processwire/processwire-issues#1097 --- .../Fieldtype/FieldtypeOptions/SelectableOptionManager.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wire/modules/Fieldtype/FieldtypeOptions/SelectableOptionManager.php b/wire/modules/Fieldtype/FieldtypeOptions/SelectableOptionManager.php index 456df1f4..241ca6fb 100644 --- a/wire/modules/Fieldtype/FieldtypeOptions/SelectableOptionManager.php +++ b/wire/modules/Fieldtype/FieldtypeOptions/SelectableOptionManager.php @@ -528,7 +528,7 @@ class SelectableOptionManager extends Wire { foreach($existingOptions as $existingOption) { $found = false; foreach($options as $option) { - if($option->id == $existingOption->id) { + if($option->id == $existingOption->id || $existingOption->id && !$option->id) { $found = true; break; }