Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

make backup settings editable at runtime

Markus Kahlf4432e999482
diff --git a/app/models/backup.rb b/app/models/backup.rb
index be4039eedbe..d3943036bb7 100644
--- a/app/models/backup.rb
+++ b/app/models/backup.rb
@@ -5,7 +5,7 @@ class Backup < Export
end
def include_attachments?
- val = OpenProject::Configuration.backup_include_attachments
+ val = Setting.backup_include_attachments
val.nil? ? true : val.to_s.to_bool # default to true
end
@@ -14,7 +14,7 @@ class Backup < Export
# Don't include attachments in archive if they are larger than
# this value combined.
def attachment_size_max_sum_mb
- (OpenProject::Configuration.backup_attachment_size_max_sum_mb.presence || 1024).to_i
+ (Setting.backup_attachment_size_max_sum_mb.presence || 1024).to_i
end
def attachments_query