Skip to content

Commit

Permalink
Fix (misskey-js): SignupResponse에 signupReason이 없음
Browse files Browse the repository at this point in the history
  • Loading branch information
HotoRas committed Oct 20, 2024
1 parent db463c9 commit c5cd665
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions packages/backend/src/models/json-schema/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ export const packedUserLiteSchema = {
example: 'misskey.example.com',
description: 'The local host is represented with `null`.',
},
signupReason: {
type: 'string',
nullable: true, optional: true,
description: 'If signup approval is required, write here why you are signing in',
},
approved: {
type: 'boolean',
nullable: false, default: false,
Expand Down
2 changes: 1 addition & 1 deletion packages/backend/test/e2e/users.ts
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ describe('ユーザー', () => {
assert.strictEqual(response.name, null);
assert.strictEqual(response.username, 'zoe');
assert.strictEqual(response.host, null);
response.avatarUrl && assert.match(response.avatarUrl, /^[-a-zA-Z0-9@:%._\+~#&?=\/]+$/);
if (response.avatarUrl) assert.match(response.avatarUrl, /^[-a-zA-Z0-9@:%._\+~#&?=\/]+$/);
assert.strictEqual(response.avatarBlurhash, null);
assert.deepStrictEqual(response.avatarDecorations, []);
assert.strictEqual(response.isBot, false);
Expand Down
2 changes: 2 additions & 0 deletions packages/misskey-js/src/autogen/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3722,6 +3722,8 @@ export type components = {
* @example misskey.example.com
*/
host: string | null;
/** @description If signup approval is required, write here why you are signing in */
signupReason?: string | null;
/**
* @description User whom registeration is approved or not
* @default false
Expand Down

0 comments on commit c5cd665

Please sign in to comment.