From f62a99882d63330ef0f66874126bc78bc98cf349 Mon Sep 17 00:00:00 2001 From: Jun Omae Date: Fri, 6 Jan 2023 17:42:45 +0900 Subject: [PATCH] Reset download limit to default after uplaoding files --- app/archive.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/archive.js b/app/archive.js index 340164e8..683cc370 100644 --- a/app/archive.js +++ b/app/archive.js @@ -17,6 +17,7 @@ export default class Archive { constructor(files = [], defaultTimeLimit = 86400, defaultDownloadLimit = 1) { this.files = Array.from(files); this.defaultTimeLimit = defaultTimeLimit; + this.defaultDownloadLimit = defaultDownloadLimit; this.timeLimit = defaultTimeLimit; this.dlimit = defaultDownloadLimit; this.password = null; @@ -76,7 +77,7 @@ export default class Archive { clear() { this.files = []; - this.dlimit = 1; + this.dlimit = this.defaultDownloadLimit; this.timeLimit = this.defaultTimeLimit; this.password = null; }