mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-30 14:13:08 +02:00
Add some indexes
This commit is contained in:
parent
7cec7fb103
commit
08531e8002
1 changed files with 2 additions and 0 deletions
|
@ -22,6 +22,8 @@ import SwSubscription, { deleteSwSubscription } from './sw-subscription';
|
|||
|
||||
const User = db.get<IUser>('users');
|
||||
|
||||
User.createIndex('username');
|
||||
User.createIndex('usernameLower');
|
||||
User.createIndex(['username', 'host'], { unique: true });
|
||||
User.createIndex(['usernameLower', 'host'], { unique: true });
|
||||
User.createIndex('token', { unique: true });
|
||||
|
|
Loading…
Reference in a new issue