From a5896799f169d3313b63165fe6a79d4149fa6df1 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 30 Apr 2020 09:28:39 +0200 Subject: Add plugin settings change watcher --- server/controllers/api/config.ts | 2 +- server/controllers/api/plugins.ts | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'server/controllers') diff --git a/server/controllers/api/config.ts b/server/controllers/api/config.ts index 85f3ad3d9..edcb0b99e 100644 --- a/server/controllers/api/config.ts +++ b/server/controllers/api/config.ts @@ -299,7 +299,7 @@ function getExternalAuthsPlugins () { name: p.name, version: p.version, authName: auth.authName, - authDisplayName: auth.authDisplayName + authDisplayName: auth.authDisplayName() }) } } diff --git a/server/controllers/api/plugins.ts b/server/controllers/api/plugins.ts index 6b7562fd3..f8a0d19ca 100644 --- a/server/controllers/api/plugins.ts +++ b/server/controllers/api/plugins.ts @@ -191,6 +191,8 @@ async function updatePluginSettings (req: express.Request, res: express.Response plugin.settings = req.body.settings await plugin.save() + await PluginManager.Instance.onSettingsChanged(plugin.name, plugin.settings) + return res.sendStatus(204) } -- cgit v1.2.3