Unable to save changes in snippet manager
Bobby_Tables
Posts: 13 Bronze 2
I have many snippets I've created the past few years and I was trying to clean up. If I delete any snippet I am unable to save changes (clicking Ok). I get the below modal. I have version: 10.13.12.1701
Stack trace from the logs.
Stack trace from the logs.
2023-07-29 23:43:19.467 -07:00 [Error] Failed to save settings due to snippet error.
System.ArgumentException: An item with the same key has already been added.
at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
at System.Linq.Enumerable.ToDictionary[TSource,TKey,TElement](IEnumerable`1 source, Func`2 keySelector, Func`2 elementSelector, IEqualityComparer`1 comparer)
at RedGate.SqlPrompt.CommonUI.Options.Pages.Snippets.ViewModels.SnippetsPageViewModel.SaveChangesToModel()
at RedGate.SqlPrompt.CommonUI.Options.Pages.Suggestions.SnippetsPage.Save()
at RedGate.SqlPrompt.CommonUI.Options.OptionsForm.OnOkButtonClicked(Object sender, EventArgs e)
Tagged:
Answers