Better deninition

This commit is contained in:
syuilo 2019-05-22 13:00:36 +09:00
parent eed9266ecb
commit 9d75ec799b
No known key found for this signature in database
GPG key ID: BDC4C49D06AB9D69
2 changed files with 14 additions and 0 deletions

View file

@ -4,6 +4,7 @@ import define from '../../../define';
import { ApiError } from '../../../error';
import { getUser } from '../../../common/getters';
import { UserGroups, UserGroupJoinings } from '../../../../../models';
import { types, bool } from '../../../../../misc/schema';
export const meta = {
desc: {
@ -31,6 +32,12 @@ export const meta = {
},
},
res: {
type: types.object,
optional: bool.false, nullable: bool.false,
ref: 'UserGroup',
},
errors: {
noSuchGroup: {
message: 'No such group.',

View file

@ -3,6 +3,7 @@ import { ID } from '../../../../../misc/cafy-id';
import define from '../../../define';
import { ApiError } from '../../../error';
import { UserGroups } from '../../../../../models';
import { types, bool } from '../../../../../misc/schema';
export const meta = {
desc: {
@ -34,6 +35,12 @@ export const meta = {
}
},
res: {
type: types.object,
optional: bool.false, nullable: bool.false,
ref: 'UserGroup',
},
errors: {
noSuchGroup: {
message: 'No such group.',