diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2019-02-24 17:57:49 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2019-02-24 17:57:49 +0900 |
| commit | f4ae9391248d9ba366210be215681537ce9ecb49 (patch) | |
| tree | 28de199e28cf57ea5254da4c1f300e16b3996a5f /src/server/api/endpoints/i/update_client_setting.ts | |
| parent | Refactor (diff) | |
| download | misskey-f4ae9391248d9ba366210be215681537ce9ecb49.tar.gz misskey-f4ae9391248d9ba366210be215681537ce9ecb49.tar.bz2 misskey-f4ae9391248d9ba366210be215681537ce9ecb49.zip | |
ハイフンに統一
Diffstat (limited to 'src/server/api/endpoints/i/update_client_setting.ts')
| -rw-r--r-- | src/server/api/endpoints/i/update_client_setting.ts | 37 |
1 files changed, 0 insertions, 37 deletions
diff --git a/src/server/api/endpoints/i/update_client_setting.ts b/src/server/api/endpoints/i/update_client_setting.ts deleted file mode 100644 index 79cd04e169..0000000000 --- a/src/server/api/endpoints/i/update_client_setting.ts +++ /dev/null @@ -1,37 +0,0 @@ -import $ from 'cafy'; -import User from '../../../../models/user'; -import { publishMainStream } from '../../../../services/stream'; -import define from '../../define'; - -export const meta = { - requireCredential: true, - - secure: true, - - params: { - name: { - validator: $.str - }, - - value: { - validator: $.nullable.any - } - } -}; - -export default define(meta, async (ps, user) => { - const x: any = {}; - x[`clientSettings.${ps.name}`] = ps.value; - - await User.update(user._id, { - $set: x - }); - - // Publish event - publishMainStream(user._id, 'clientSettingUpdated', { - key: ps.name, - value: ps.value - }); - - return; -}); |