summaryrefslogtreecommitdiff
path: root/src/server/api/endpoints/i/notifications.ts
diff options
context:
space:
mode:
authorsyuilo <Syuilotan@yahoo.co.jp>2019-04-23 22:35:26 +0900
committerGitHub <noreply@github.com>2019-04-23 22:35:26 +0900
commit0463c6bb0f8fd32740ceb61ccce04c662272a618 (patch)
treea28cbdf6c9cdc14648b8c0e46248665a3ad7e5af /src/server/api/endpoints/i/notifications.ts
parentFix #4768 (diff)
downloadsharkey-0463c6bb0f8fd32740ceb61ccce04c662272a618.tar.gz
sharkey-0463c6bb0f8fd32740ceb61ccce04c662272a618.tar.bz2
sharkey-0463c6bb0f8fd32740ceb61ccce04c662272a618.zip
Refactor API (#4770)
* wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * Update description.ts * wip
Diffstat (limited to 'src/server/api/endpoints/i/notifications.ts')
-rw-r--r--src/server/api/endpoints/i/notifications.ts10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/server/api/endpoints/i/notifications.ts b/src/server/api/endpoints/i/notifications.ts
index 56074c9d00..41513e5daa 100644
--- a/src/server/api/endpoints/i/notifications.ts
+++ b/src/server/api/endpoints/i/notifications.ts
@@ -4,6 +4,7 @@ import { readNotification } from '../../common/read-notification';
import define from '../../define';
import { makePaginationQuery } from '../../common/make-pagination-query';
import { Notifications, Followings, Mutings } from '../../../../models';
+import { types, bool } from '../../../../misc/schema';
export const meta = {
desc: {
@@ -53,10 +54,13 @@ export const meta = {
},
res: {
- type: 'array',
+ type: types.array,
+ optional: bool.false, nullable: bool.false,
items: {
- type: 'Notification',
- },
+ type: types.object,
+ optional: bool.false, nullable: bool.false,
+ ref: 'Notification',
+ }
},
};