diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2018-04-29 17:17:15 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2018-04-29 17:17:15 +0900 |
| commit | 372bfaceda5bf694bf33986b5a64a56e5787104c (patch) | |
| tree | c498cd9fac2f79404e2d5b74549a5d759257ddcf /src/server/api/endpoints/i | |
| parent | Merge pull request #1559 from syuilo/visibility (diff) | |
| download | sharkey-372bfaceda5bf694bf33986b5a64a56e5787104c.tar.gz sharkey-372bfaceda5bf694bf33986b5a64a56e5787104c.tar.bz2 sharkey-372bfaceda5bf694bf33986b5a64a56e5787104c.zip | |
リファクタリングなど
Diffstat (limited to 'src/server/api/endpoints/i')
| -rw-r--r-- | src/server/api/endpoints/i/update_client_setting.ts | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/src/server/api/endpoints/i/update_client_setting.ts b/src/server/api/endpoints/i/update_client_setting.ts index 2edc2104d2..278eb1cbeb 100644 --- a/src/server/api/endpoints/i/update_client_setting.ts +++ b/src/server/api/endpoints/i/update_client_setting.ts @@ -24,16 +24,11 @@ module.exports = async (params, user) => new Promise(async (res, rej) => { $set: x }); - // Serialize - user.clientSettings[name] = value; - const iObj = await pack(user, user, { - detail: true, - includeSecrets: true - }); - - // Send response - res(iObj); + res(); - // Publish i updated event - event(user._id, 'i_updated', iObj); + // Publish event + event(user._id, 'clientSettingUpdated', { + key: name, + value + }); }); |