mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 23:40:13 +01:00
Merge branch 'upgrade-meteor-2.6' of https://github.com/majus/wekan into upgrade-meteor
This commit is contained in:
commit
0c3ca14699
268 changed files with 3109 additions and 10419 deletions
|
|
@ -1,6 +1,5 @@
|
|||
import { Meteor } from 'meteor/meteor';
|
||||
import { FilesCollection } from 'meteor/ostrio:files';
|
||||
import fs from 'fs';
|
||||
import path from 'path';
|
||||
import { createBucket } from './lib/grid/createBucket';
|
||||
import { createOnAfterUpload } from './lib/fsHooks/createOnAfterUpload';
|
||||
|
|
@ -83,12 +82,7 @@ if (Meteor.isServer) {
|
|||
});
|
||||
|
||||
Meteor.startup(() => {
|
||||
Attachments.collection._ensureIndex({ 'meta.cardId': 1 });
|
||||
const storagePath = Attachments.storagePath();
|
||||
if (!fs.existsSync(storagePath)) {
|
||||
console.log("create storagePath because it doesn't exist: " + storagePath);
|
||||
fs.mkdirSync(storagePath, { recursive: true });
|
||||
}
|
||||
Attachments.collection.createIndex({ cardId: 1 });
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue