summaryrefslogtreecommitdiff
path: root/src/api/endpoints/following/create.ts
diff options
context:
space:
mode:
authorsyuilo <syuilotan@yahoo.co.jp>2017-03-09 03:50:09 +0900
committersyuilo <syuilotan@yahoo.co.jp>2017-03-09 03:50:09 +0900
commit31f36fa618e02bab9776a943366167e1009ede48 (patch)
tree386dbaa963b3695f6a0febf9b5076e8d42006536 /src/api/endpoints/following/create.ts
parentMerge pull request #237 from syuilo/greenkeeper/cafy-1.2.0 (diff)
downloadmisskey-31f36fa618e02bab9776a943366167e1009ede48.tar.gz
misskey-31f36fa618e02bab9776a943366167e1009ede48.tar.bz2
misskey-31f36fa618e02bab9776a943366167e1009ede48.zip
:v:
Diffstat (limited to 'src/api/endpoints/following/create.ts')
-rw-r--r--src/api/endpoints/following/create.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/api/endpoints/following/create.ts b/src/api/endpoints/following/create.ts
index 28a69844c2..b4a2217b16 100644
--- a/src/api/endpoints/following/create.ts
+++ b/src/api/endpoints/following/create.ts
@@ -1,7 +1,7 @@
/**
* Module dependencies
*/
-import it from 'cafy';
+import $ from 'cafy';
import User from '../../models/user';
import Following from '../../models/following';
import notify from '../../common/notify';
@@ -19,7 +19,7 @@ module.exports = (params, user) => new Promise(async (res, rej) => {
const follower = user;
// Get 'user_id' parameter
- const [userId, userIdErr] = it(params.user_id, 'id!').get();
+ const [userId, userIdErr] = $(params.user_id).id().$;
if (userIdErr) return rej('invalid user_id param');
// 自分自身