summaryrefslogtreecommitdiff
path: root/src/server/api/endpoints/i/update_home.ts
diff options
context:
space:
mode:
authorsyuilo <syuilotan@yahoo.co.jp>2018-04-08 03:58:11 +0900
committersyuilo <syuilotan@yahoo.co.jp>2018-04-08 03:58:11 +0900
commita02ee3a08bac55c9f0b29cb6bc0a15726b7cc3c8 (patch)
treebf3c3dacd69737bf79eea0311fed1ddc504b15a5 /src/server/api/endpoints/i/update_home.ts
parentPost --> Note (diff)
downloadmisskey-a02ee3a08bac55c9f0b29cb6bc0a15726b7cc3c8.tar.gz
misskey-a02ee3a08bac55c9f0b29cb6bc0a15726b7cc3c8.tar.bz2
misskey-a02ee3a08bac55c9f0b29cb6bc0a15726b7cc3c8.zip
Some bug fixes
Diffstat (limited to 'src/server/api/endpoints/i/update_home.ts')
-rw-r--r--src/server/api/endpoints/i/update_home.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/server/api/endpoints/i/update_home.ts b/src/server/api/endpoints/i/update_home.ts
index 91be0714d7..ce7661ede0 100644
--- a/src/server/api/endpoints/i/update_home.ts
+++ b/src/server/api/endpoints/i/update_home.ts
@@ -26,7 +26,7 @@ module.exports = async (params, user) => new Promise(async (res, rej) => {
if (home) {
await User.update(user._id, {
$set: {
- 'account.clientSettings.home': home
+ 'clientSettings.home': home
}
});
@@ -38,7 +38,7 @@ module.exports = async (params, user) => new Promise(async (res, rej) => {
} else {
if (id == null && data == null) return rej('you need to set id and data params if home param unset');
- const _home = user.account.clientSettings.home;
+ const _home = user.clientSettings.home;
const widget = _home.find(w => w.id == id);
if (widget == null) return rej('widget not found');
@@ -47,7 +47,7 @@ module.exports = async (params, user) => new Promise(async (res, rej) => {
await User.update(user._id, {
$set: {
- 'account.clientSettings.home': _home
+ 'clientSettings.home': _home
}
});