diff options
| author | syuilo <Syuilotan@yahoo.co.jp> | 2018-02-23 02:13:40 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-02-23 02:13:40 +0900 |
| commit | d1785848289397b9e8242edd9bd87c5906fe5eb7 (patch) | |
| tree | 8cb4ff23a694f95bc8f4895698b6202090c26554 /src/api/endpoints/i/update.ts | |
| parent | Merge pull request #1097 from syuilo/refactor (diff) | |
| parent | wip (diff) | |
| download | misskey-d1785848289397b9e8242edd9bd87c5906fe5eb7.tar.gz misskey-d1785848289397b9e8242edd9bd87c5906fe5eb7.tar.bz2 misskey-d1785848289397b9e8242edd9bd87c5906fe5eb7.zip | |
Merge pull request #1116 from syuilo/vue-#972
Migrate to Vue
Diffstat (limited to 'src/api/endpoints/i/update.ts')
| -rw-r--r-- | src/api/endpoints/i/update.ts | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/api/endpoints/i/update.ts b/src/api/endpoints/i/update.ts index 7bbbf95900..43c5245044 100644 --- a/src/api/endpoints/i/update.ts +++ b/src/api/endpoints/i/update.ts @@ -46,19 +46,13 @@ module.exports = async (params, user, _, isSecure) => new Promise(async (res, re if (bannerIdErr) return rej('invalid banner_id param'); if (bannerId) user.banner_id = bannerId; - // Get 'show_donation' parameter - const [showDonation, showDonationErr] = $(params.show_donation).optional.boolean().$; - if (showDonationErr) return rej('invalid show_donation param'); - if (showDonation) user.client_settings.show_donation = showDonation; - await User.update(user._id, { $set: { name: user.name, description: user.description, avatar_id: user.avatar_id, banner_id: user.banner_id, - profile: user.profile, - 'client_settings.show_donation': user.client_settings.show_donation + profile: user.profile } }); |