refactor reloadSettings
This commit is contained in:
1 parent
f4bbbc5fa9
commit
114f4ffb05
2 files changed
+11
-18
No files matched your search
@@ -31,11 +31,11 @@ const updateAppSettings = async (req, res, next) => {
|
||||
|
||||
try {
|
||||
const settings = await req.db.updateAppSettings(req.body);
|
||||
await req.settingsService.reloadSettings();
|
||||
const updatedSettings = await req.settingsService.reloadSettings();
|
||||
return res.status(200).json({
|
||||
success: true,
|
||||
msg: successMessages.UPDATE_APP_SETTINGS,
|
||||
data: settings,
|
||||
data: updatedSettings,
|
||||
});
|
||||
} catch (error) {
|
||||
error.service === undefined ? (error.service = SERVICE_NAME) : null;
|
||||
|
||||
Reference in new issue
Block a user