fix: harden plugin auto-enable empty config handling

This commit is contained in:
Peter Steinberger
2026-04-02 15:19:18 +01:00
parent b40ef364b7
commit ef86edacf7
6 changed files with 19 additions and 6 deletions

View File

@@ -306,9 +306,9 @@ describe("resolvePluginWebSearchProviders", () => {
applyPluginAutoEnableSpy = vi
.spyOn(pluginAutoEnableModule, "applyPluginAutoEnable")
.mockImplementation(
(params: { config: unknown }) =>
(params) =>
({
config: params.config,
config: params.config ?? {},
changes: [],
autoEnabledReasons: {},
}) as ReturnType<PluginAutoEnableModule["applyPluginAutoEnable"]>,