forked from FoundKeyGang/FoundKey
Fix bug
This commit is contained in:
parent
a6fb4f2e33
commit
862463a13c
1 changed files with 3 additions and 1 deletions
|
@ -19,6 +19,7 @@ export default async (job: kue.Job, done): Promise<void> => {
|
||||||
if (host === null) {
|
if (host === null) {
|
||||||
console.warn(`request was made by local user: @${username}`);
|
console.warn(`request was made by local user: @${username}`);
|
||||||
done();
|
done();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
user = await User.findOne({ usernameLower: username, hostLower: host }) as IRemoteUser;
|
user = await User.findOne({ usernameLower: username, hostLower: host }) as IRemoteUser;
|
||||||
|
@ -40,7 +41,8 @@ export default async (job: kue.Job, done): Promise<void> => {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!verifySignature(signature, user.account.publicKey.publicKeyPem)) {
|
if (!verifySignature(signature, user.account.publicKey.publicKeyPem)) {
|
||||||
done(new Error('signature verification failed'));
|
console.warn('signature verification failed');
|
||||||
|
done();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue