Better error handling
This commit is contained in:
parent
b390363b25
commit
e3b3f8fac1
25 changed files with 52 additions and 52 deletions
|
|
@ -15,7 +15,7 @@ async function main(username: string, headers?: string[]) {
|
|||
usernameLower: username.toLowerCase(),
|
||||
});
|
||||
|
||||
if (user == null) throw 'User not found';
|
||||
if (user == null) throw new Error('User not found');
|
||||
|
||||
const history = await Signins.find({
|
||||
userId: user.id
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue