From 89747b5fa9ab14beb8eea114386131ee3c791d2c Mon Sep 17 00:00:00 2001 From: OMGUSED Date: Thu, 27 May 2021 22:48:48 +0200 Subject: [PATCH] Update CloneFieldsControl.cs Bug Fix: Removed renaming of OptionSet for attributes that use global OptionSets --- .../CloneFieldsControl.cs | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/lib/MsDyn.Contrib.CloneFieldDefinitions/CloneFieldsControl.cs b/src/lib/MsDyn.Contrib.CloneFieldDefinitions/CloneFieldsControl.cs index 066bd9a..5d28939 100644 --- a/src/lib/MsDyn.Contrib.CloneFieldDefinitions/CloneFieldsControl.cs +++ b/src/lib/MsDyn.Contrib.CloneFieldDefinitions/CloneFieldsControl.cs @@ -725,16 +725,6 @@ private void CloneOptionSetAttribute(string sourceEntityName, string targetEntit optionSetAttribute.OptionSet.MetadataId = Guid.NewGuid(); optionSetAttribute.OptionSet.Name = optionSetAttribute.OptionSet.Name.ReplaceEntityName(sourceEntityName, targetEntityName); } - else if (optionSetAttribute?.OptionSet?.IsGlobal != null && - optionSetAttribute.OptionSet.IsGlobal.Value) - { - optionSetAttribute.OptionSet.MetadataId = Guid.NewGuid(); - optionSetAttribute.OptionSet.IsGlobal = true; - optionSetAttribute.OptionSet.Name = optionSetAttribute.OptionSet.Name.Replace(sourceEntityName, - targetEntityName); - optionSetAttribute.OptionSet.Options.Clear(); - - } } private void CloneBooleanAttribute(string sourceEntityName, string targetEntityName, AttributeMetadata attribute)