summaryrefslogtreecommitdiff
path: root/src/models
diff options
context:
space:
mode:
Diffstat (limited to 'src/models')
-rw-r--r--src/models/meta.ts13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/models/meta.ts b/src/models/meta.ts
index 7caf41f19c..073be7de82 100644
--- a/src/models/meta.ts
+++ b/src/models/meta.ts
@@ -50,6 +50,17 @@ if ((config as any).remoteDriveCapacityMb) {
}
});
}
+if ((config as any).preventCacheRemoteFiles) {
+ Meta.findOne({}).then(m => {
+ if (m != null && m.cacheRemoteFiles == null) {
+ Meta.update({}, {
+ $set: {
+ cacheRemoteFiles: !(config as any).preventCacheRemoteFiles
+ }
+ });
+ }
+ });
+}
export type IMeta = {
name?: string;
@@ -66,6 +77,8 @@ export type IMeta = {
hidedTags?: string[];
bannerUrl?: string;
+ cacheRemoteFiles?: boolean;
+
/**
* Drive capacity of a local user (MB)
*/