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

Prefer symbols and freeze constants

Kabiru Mwenja0d08b13e17bd
diff --git a/app/models/user_preference.rb b/app/models/user_preference.rb
index 9b23607041f..82f25a4e87b 100644
--- a/app/models/user_preference.rb
+++ b/app/models/user_preference.rb
@@ -38,8 +38,8 @@ class UserPreference < ApplicationRecord
WORKDAYS_FROM_MONDAY_TO_FRIDAY = [1, 2, 3, 4, 5].freeze
- COLOR_MODES = %w[light dark].freeze
- THEMES = COLOR_MODES + %w[sync_with_os].freeze
+ COLOR_MODES = %i[light dark].freeze
+ THEMES = (COLOR_MODES + %i[sync_with_os]).freeze
##
# Retrieve keys from settings, and allow accessing