fix lint
This commit is contained in:
@@ -15,16 +15,16 @@ export const meta = {
|
||||
|
||||
params: {
|
||||
name: {
|
||||
validator: $.str.range(1, 128)
|
||||
validator: $.str.range(1, 128),
|
||||
},
|
||||
|
||||
description: {
|
||||
validator: $.nullable.optional.str.range(1, 2048)
|
||||
validator: $.nullable.optional.str.range(1, 2048),
|
||||
},
|
||||
|
||||
bannerId: {
|
||||
validator: $.nullable.optional.type(ID),
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
res: {
|
||||
@@ -37,9 +37,9 @@ export const meta = {
|
||||
noSuchFile: {
|
||||
message: 'No such file.',
|
||||
code: 'NO_SUCH_FILE',
|
||||
id: 'cd1e9f3e-5a12-4ab4-96f6-5d0a2cc32050'
|
||||
id: 'cd1e9f3e-5a12-4ab4-96f6-5d0a2cc32050',
|
||||
},
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, user) => {
|
||||
@@ -47,7 +47,7 @@ export default define(meta, async (ps, user) => {
|
||||
if (ps.bannerId != null) {
|
||||
banner = await DriveFiles.findOne({
|
||||
id: ps.bannerId,
|
||||
userId: user.id
|
||||
userId: user.id,
|
||||
});
|
||||
|
||||
if (banner == null) {
|
||||
|
@@ -13,7 +13,7 @@ export const meta = {
|
||||
type: 'object' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
ref: 'Channel',
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
|
@@ -23,9 +23,9 @@ export const meta = {
|
||||
noSuchChannel: {
|
||||
message: 'No such channel.',
|
||||
code: 'NO_SUCH_CHANNEL',
|
||||
id: 'c0031718-d573-4e85-928e-10039f1fbb68'
|
||||
id: 'c0031718-d573-4e85-928e-10039f1fbb68',
|
||||
},
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, user) => {
|
||||
|
@@ -22,7 +22,7 @@ export const meta = {
|
||||
|
||||
limit: {
|
||||
validator: $.optional.num.range(1, 100),
|
||||
default: 5
|
||||
default: 5,
|
||||
},
|
||||
},
|
||||
|
||||
@@ -33,7 +33,7 @@ export const meta = {
|
||||
type: 'object' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
ref: 'Channel',
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
|
@@ -22,7 +22,7 @@ export const meta = {
|
||||
|
||||
limit: {
|
||||
validator: $.optional.num.range(1, 100),
|
||||
default: 5
|
||||
default: 5,
|
||||
},
|
||||
},
|
||||
|
||||
@@ -33,7 +33,7 @@ export const meta = {
|
||||
type: 'object' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
ref: 'Channel',
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
|
@@ -25,9 +25,9 @@ export const meta = {
|
||||
noSuchChannel: {
|
||||
message: 'No such channel.',
|
||||
code: 'NO_SUCH_CHANNEL',
|
||||
id: '6f6c314b-7486-4897-8966-c04a66a02923'
|
||||
id: '6f6c314b-7486-4897-8966-c04a66a02923',
|
||||
},
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, me) => {
|
||||
|
@@ -45,16 +45,16 @@ export const meta = {
|
||||
type: 'object' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
ref: 'Note',
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
errors: {
|
||||
noSuchChannel: {
|
||||
message: 'No such channel.',
|
||||
code: 'NO_SUCH_CHANNEL',
|
||||
id: '4d0eeeba-a02c-4c3c-9966-ef60d38d2e7f'
|
||||
}
|
||||
}
|
||||
id: '4d0eeeba-a02c-4c3c-9966-ef60d38d2e7f',
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, user) => {
|
||||
|
@@ -22,9 +22,9 @@ export const meta = {
|
||||
noSuchChannel: {
|
||||
message: 'No such channel.',
|
||||
code: 'NO_SUCH_CHANNEL',
|
||||
id: '19959ee9-0153-4c51-bbd9-a98c49dc59d6'
|
||||
id: '19959ee9-0153-4c51-bbd9-a98c49dc59d6',
|
||||
},
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, user) => {
|
||||
|
@@ -17,16 +17,16 @@ export const meta = {
|
||||
},
|
||||
|
||||
name: {
|
||||
validator: $.optional.str.range(1, 128)
|
||||
validator: $.optional.str.range(1, 128),
|
||||
},
|
||||
|
||||
description: {
|
||||
validator: $.nullable.optional.str.range(1, 2048)
|
||||
validator: $.nullable.optional.str.range(1, 2048),
|
||||
},
|
||||
|
||||
bannerId: {
|
||||
validator: $.nullable.optional.type(ID),
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
res: {
|
||||
@@ -39,21 +39,21 @@ export const meta = {
|
||||
noSuchChannel: {
|
||||
message: 'No such channel.',
|
||||
code: 'NO_SUCH_CHANNEL',
|
||||
id: 'f9c5467f-d492-4c3c-9a8d-a70dacc86512'
|
||||
id: 'f9c5467f-d492-4c3c-9a8d-a70dacc86512',
|
||||
},
|
||||
|
||||
accessDenied: {
|
||||
message: 'You do not have edit privilege of the channel.',
|
||||
code: 'ACCESS_DENIED',
|
||||
id: '1fb7cb09-d46a-4fdf-b8df-057788cce513'
|
||||
id: '1fb7cb09-d46a-4fdf-b8df-057788cce513',
|
||||
},
|
||||
|
||||
noSuchFile: {
|
||||
message: 'No such file.',
|
||||
code: 'NO_SUCH_FILE',
|
||||
id: 'e86c14a4-0da2-4032-8df3-e737a04c7f3b'
|
||||
id: 'e86c14a4-0da2-4032-8df3-e737a04c7f3b',
|
||||
},
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, me) => {
|
||||
@@ -74,7 +74,7 @@ export default define(meta, async (ps, me) => {
|
||||
if (ps.bannerId != null) {
|
||||
banner = await DriveFiles.findOne({
|
||||
id: ps.bannerId,
|
||||
userId: me.id
|
||||
userId: me.id,
|
||||
});
|
||||
|
||||
if (banner == null) {
|
||||
|
Reference in New Issue
Block a user