mirror of
https://github.com/misskey-dev/misskey.git
synced 2025-01-10 19:42:41 +01:00
JSON.stringify
This commit is contained in:
parent
1690e0617e
commit
da4a44b337
1 changed files with 3 additions and 3 deletions
|
@ -124,12 +124,12 @@ export class ApDbResolverService implements OnApplicationShutdown {
|
||||||
this.refreshCacheByUserId(userId);
|
this.refreshCacheByUserId(userId);
|
||||||
const keys = await this.getPublicKeyByUserId(userId);
|
const keys = await this.getPublicKeyByUserId(userId);
|
||||||
if (keys == null || !Array.isArray(keys) || keys.length === 0) {
|
if (keys == null || !Array.isArray(keys) || keys.length === 0) {
|
||||||
this.logger.warn(`No key found (refreshAndfindKey) userId=${userId} keyId=${keyId} keys=${keys}`);
|
this.logger.warn(`No key found (refreshAndfindKey) userId=${userId} keyId=${keyId} keys=${JSON.stringify(keys)}`);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
const exactKey = keys.find(x => x.keyId === keyId);
|
const exactKey = keys.find(x => x.keyId === keyId);
|
||||||
if (exactKey) return exactKey;
|
if (exactKey) return exactKey;
|
||||||
this.logger.warn(`No exact key found (refreshAndfindKey) userId=${userId} keyId=${keyId} keys=${keys}`);
|
this.logger.warn(`No exact key found (refreshAndfindKey) userId=${userId} keyId=${keyId} keys=${JSON.stringify(keys)}`);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -149,7 +149,7 @@ export class ApDbResolverService implements OnApplicationShutdown {
|
||||||
const keys = await this.getPublicKeyByUserId(user.id);
|
const keys = await this.getPublicKeyByUserId(user.id);
|
||||||
|
|
||||||
if (keys == null || !Array.isArray(keys) || keys.length === 0) {
|
if (keys == null || !Array.isArray(keys) || keys.length === 0) {
|
||||||
this.logger.warn(`No key found uri=${uri} userId=${user.id} keys=${keys}`);
|
this.logger.warn(`No key found uri=${uri} userId=${user.id} keys=${JSON.stringify(keys)}`);
|
||||||
return { user, key: null };
|
return { user, key: null };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue