mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-05-16 08:35:24 +02:00
Use createIndex() instead of index() to avoid deprecation warnings
This commit is contained in:
@@ -2,8 +2,8 @@ import db from '../../db/mongodb';
|
||||
|
||||
const collection = db.get('users');
|
||||
|
||||
(collection as any).index('username'); // fuck type definition
|
||||
(collection as any).index('token'); // fuck type definition
|
||||
(collection as any).createIndex('username'); // fuck type definition
|
||||
(collection as any).createIndex('token'); // fuck type definition
|
||||
|
||||
export default collection as any; // fuck type definition
|
||||
|
||||
|
||||
Reference in New Issue
Block a user