diff options
| author | syuilo <Syuilotan@yahoo.co.jp> | 2018-07-07 02:55:52 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-07-07 02:55:52 +0900 |
| commit | d5bad25c63f1b1d095da8b523dc02be471d7071a (patch) | |
| tree | 381ce23594925e56ba09c16de076932193f35b47 /src/server/api/endpoints/users/lists | |
| parent | Merge pull request #1846 from syuilo/l10n_master (diff) | |
| parent | w (diff) | |
| download | misskey-d5bad25c63f1b1d095da8b523dc02be471d7071a.tar.gz misskey-d5bad25c63f1b1d095da8b523dc02be471d7071a.tar.bz2 misskey-d5bad25c63f1b1d095da8b523dc02be471d7071a.zip | |
Merge pull request #1854 from syuilo/apis
:v:
Diffstat (limited to 'src/server/api/endpoints/users/lists')
| -rw-r--r-- | src/server/api/endpoints/users/lists/create.ts | 2 | ||||
| -rw-r--r-- | src/server/api/endpoints/users/lists/list.ts | 2 | ||||
| -rw-r--r-- | src/server/api/endpoints/users/lists/push.ts | 2 | ||||
| -rw-r--r-- | src/server/api/endpoints/users/lists/show.ts | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/src/server/api/endpoints/users/lists/create.ts b/src/server/api/endpoints/users/lists/create.ts index cdd1a0d813..f3776afee0 100644 --- a/src/server/api/endpoints/users/lists/create.ts +++ b/src/server/api/endpoints/users/lists/create.ts @@ -5,7 +5,7 @@ import { ILocalUser } from '../../../../../models/user'; /** * Create a user list */ -module.exports = async (params: any, user: ILocalUser) => new Promise(async (res, rej) => { +export default async (params: any, user: ILocalUser) => new Promise(async (res, rej) => { // Get 'title' parameter const [title, titleErr] = $.str.range(1, 100).get(params.title); if (titleErr) return rej('invalid title param'); diff --git a/src/server/api/endpoints/users/lists/list.ts b/src/server/api/endpoints/users/lists/list.ts index bf8391d863..88fa75a111 100644 --- a/src/server/api/endpoints/users/lists/list.ts +++ b/src/server/api/endpoints/users/lists/list.ts @@ -4,7 +4,7 @@ import { ILocalUser } from '../../../../../models/user'; /** * Add a user to a user list */ -module.exports = async (params: any, me: ILocalUser) => new Promise(async (res, rej) => { +export default async (params: any, me: ILocalUser) => new Promise(async (res, rej) => { // Fetch lists const userLists = await UserList.find({ userId: me._id, diff --git a/src/server/api/endpoints/users/lists/push.ts b/src/server/api/endpoints/users/lists/push.ts index d8a3b3c9aa..0e7caea064 100644 --- a/src/server/api/endpoints/users/lists/push.ts +++ b/src/server/api/endpoints/users/lists/push.ts @@ -9,7 +9,7 @@ import { deliver } from '../../../../../queue'; /** * Add a user to a user list */ -module.exports = async (params: any, me: ILocalUser) => new Promise(async (res, rej) => { +export default async (params: any, me: ILocalUser) => new Promise(async (res, rej) => { // Get 'listId' parameter const [listId, listIdErr] = $.type(ID).get(params.listId); if (listIdErr) return rej('invalid listId param'); diff --git a/src/server/api/endpoints/users/lists/show.ts b/src/server/api/endpoints/users/lists/show.ts index e4ae239613..4716dd8211 100644 --- a/src/server/api/endpoints/users/lists/show.ts +++ b/src/server/api/endpoints/users/lists/show.ts @@ -5,7 +5,7 @@ import { ILocalUser } from '../../../../../models/user'; /** * Show a user list */ -module.exports = async (params: any, me: ILocalUser) => new Promise(async (res, rej) => { +export default async (params: any, me: ILocalUser) => new Promise(async (res, rej) => { // Get 'listId' parameter const [listId, listIdErr] = $.type(ID).get(params.listId); if (listIdErr) return rej('invalid listId param'); |