mirror of
https://github.com/misskey-dev/misskey.git
synced 2024-11-26 06:08:13 +01:00
refactor(backend): 必要ないas anyを消去 (#10293)
This commit is contained in:
parent
65b1524f92
commit
0ac1fc846b
5 changed files with 6 additions and 5 deletions
|
@ -90,7 +90,7 @@ export class SignupService {
|
||||||
cipher: undefined,
|
cipher: undefined,
|
||||||
passphrase: undefined,
|
passphrase: undefined,
|
||||||
},
|
},
|
||||||
} as any, (err, publicKey, privateKey) =>
|
}, (err, publicKey, privateKey) =>
|
||||||
err ? rej(err) : res([publicKey, privateKey]),
|
err ? rej(err) : res([publicKey, privateKey]),
|
||||||
));
|
));
|
||||||
|
|
||||||
|
|
|
@ -140,7 +140,7 @@ export class ApInboxService {
|
||||||
} else if (isFlag(activity)) {
|
} else if (isFlag(activity)) {
|
||||||
await this.flag(actor, activity);
|
await this.flag(actor, activity);
|
||||||
} else {
|
} else {
|
||||||
this.logger.warn(`unrecognized activity type: ${(activity as any).type}`);
|
this.logger.warn(`unrecognized activity type: ${activity.type}`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -124,7 +124,7 @@ export class ApNoteService {
|
||||||
throw new Error('invalid note');
|
throw new Error('invalid note');
|
||||||
}
|
}
|
||||||
|
|
||||||
const note: IPost = object as any;
|
const note = object as IPost;
|
||||||
|
|
||||||
this.logger.debug(`Note fetched: ${JSON.stringify(note, null, 2)}`);
|
this.logger.debug(`Note fetched: ${JSON.stringify(note, null, 2)}`);
|
||||||
|
|
||||||
|
|
|
@ -195,7 +195,8 @@ export const isPropertyValue = (object: IObject): object is IApPropertyValue =>
|
||||||
object &&
|
object &&
|
||||||
getApType(object) === 'PropertyValue' &&
|
getApType(object) === 'PropertyValue' &&
|
||||||
typeof object.name === 'string' &&
|
typeof object.name === 'string' &&
|
||||||
typeof (object as any).value === 'string';
|
'value' in object &&
|
||||||
|
typeof object.value === 'string';
|
||||||
|
|
||||||
export interface IApMention extends IObject {
|
export interface IApMention extends IObject {
|
||||||
type: 'Mention';
|
type: 'Mention';
|
||||||
|
|
|
@ -64,7 +64,7 @@ export class InboxProcessorService {
|
||||||
const activity = job.data.activity;
|
const activity = job.data.activity;
|
||||||
|
|
||||||
//#region Log
|
//#region Log
|
||||||
const info = Object.assign({}, activity) as any;
|
const info = Object.assign({}, activity);
|
||||||
delete info['@context'];
|
delete info['@context'];
|
||||||
this.logger.debug(JSON.stringify(info, null, 2));
|
this.logger.debug(JSON.stringify(info, null, 2));
|
||||||
//#endregion
|
//#endregion
|
||||||
|
|
Loading…
Reference in a new issue