Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[editor] Only Persist Changed Model Settings (#551)
# Only Persist Changed Model Settings Fix a bug in the settings renderer copied from workbooks -- currently, just opening the settings tab and saving the workbook will persist a model settings object for the prompt. The cause of this is the use of the `useEffect` for handling changes -- `useEffect` will always run once on mount of the component so it was always persisting the empty settings on mount. To fix, just check that the value has actually changed before persisting it to the config. ## Testing: - Open settings & save config without touching anything. See the config has no changes - Change system prompt and save, ensure it's persisted to the config --- Stack created with [Sapling](https://sapling-scm.com). Best reviewed with [ReviewStack](https://reviewstack.dev/lastmile-ai/aiconfig/pull/551). * #552 * __->__ #551
- Loading branch information