summaryrefslogtreecommitdiff
path: root/src/api
diff options
context:
space:
mode:
Diffstat (limited to 'src/api')
-rw-r--r--src/api/models/drive-file.ts6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/api/models/drive-file.ts b/src/api/models/drive-file.ts
index b7b44c5722..4c7204b1f4 100644
--- a/src/api/models/drive-file.ts
+++ b/src/api/models/drive-file.ts
@@ -1,6 +1,10 @@
import db from '../../db/mongodb';
-export default db.get('drive_files') as any; // fuck type definition
+const collection = db.get('drive_files');
+
+(collection as any).index('hash'); // fuck type definition
+
+export default collection as any; // fuck type definition
export function validateFileName(name: string): boolean {
return (