summaryrefslogtreecommitdiff
path: root/src/api/endpoints/aggregation/users
diff options
context:
space:
mode:
authorsyuilo <syuilotan@yahoo.co.jp>2017-05-24 16:29:00 +0900
committersyuilo <syuilotan@yahoo.co.jp>2017-05-24 16:29:00 +0900
commit39edc11ad8b51a012155f086473b42be66fe2fad (patch)
tree1372ebeb9bb300310f619ae50b0a3909a000ec1c /src/api/endpoints/aggregation/users
parentAdd info to error message (diff)
downloadsharkey-39edc11ad8b51a012155f086473b42be66fe2fad.tar.gz
sharkey-39edc11ad8b51a012155f086473b42be66fe2fad.tar.bz2
sharkey-39edc11ad8b51a012155f086473b42be66fe2fad.zip
Fix iroiro
Diffstat (limited to 'src/api/endpoints/aggregation/users')
-rw-r--r--src/api/endpoints/aggregation/users/reaction.ts (renamed from src/api/endpoints/aggregation/users/like.ts)6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/api/endpoints/aggregation/users/like.ts b/src/api/endpoints/aggregation/users/reaction.ts
index 239acd2931..8f1919fa69 100644
--- a/src/api/endpoints/aggregation/users/like.ts
+++ b/src/api/endpoints/aggregation/users/reaction.ts
@@ -3,10 +3,10 @@
*/
import $ from 'cafy';
import User from '../../../models/user';
-import Like from '../../../models/like';
+import Reaction from '../../../models/post-reaction';
/**
- * Aggregate like of a user
+ * Aggregate reaction of a user
*
* @param {any} params
* @return {Promise<any>}
@@ -29,7 +29,7 @@ module.exports = (params) => new Promise(async (res, rej) => {
return rej('user not found');
}
- const datas = await Like
+ const datas = await Reaction
.aggregate([
{ $match: { user_id: user._id } },
{ $project: {