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

Fixes Performance/EndWith offenses

Klaus Zandersa55b77207e09
diff --git a/app/contracts/user_preferences/base_contract.rb b/app/contracts/user_preferences/base_contract.rb
index 198e6ee53b9..056d5a52c1a 100644
--- a/app/contracts/user_preferences/base_contract.rb
+++ b/app/contracts/user_preferences/base_contract.rb
@@ -109,7 +109,7 @@ module UserPreferences
end
def full_hour_reminder_time
- unless model.daily_reminders[:times].all? { |time| time.match?(/00:00\+00:00\z/) }
+ unless model.daily_reminders[:times].all? { |time| time.end_with?('00:00+00:00') }
errors.add :daily_reminders, :full_hour
end
end