Maintenance: Bump rubocop-rails from 2.13.1 to 2.13.2

Bumps [rubocop-rails](https://github.com/rubocop/rubocop-rails) from 2.13.1 to 2.13.2.
- [Release notes](https://github.com/rubocop/rubocop-rails/releases)
- [Changelog](https://github.com/rubocop/rubocop-rails/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rubocop/rubocop-rails/compare/v2.13.1...v2.13.2)
This commit is contained in:
Martin Gruner 2022-01-18 07:20:33 +01:00
parent 84b071a039
commit 4018904fd8
4 changed files with 14 additions and 14 deletions

View file

@ -527,7 +527,7 @@ GEM
rubocop-performance (1.13.2)
rubocop (>= 1.7.0, < 2.0)
rubocop-ast (>= 0.4.0)
rubocop-rails (2.13.1)
rubocop-rails (2.13.2)
activesupport (>= 4.2.0)
rack (>= 1.1)
rubocop (>= 1.7.0, < 2.0)

View file

@ -235,8 +235,8 @@ returns
if event.rrule
# loop till days
interval_frame_start = Date.parse("#{Time.zone.now - 1.year}-01-01")
interval_frame_end = Date.parse("#{Time.zone.now + 3.years}-12-31")
interval_frame_start = Date.parse("#{1.year.ago}-01-01")
interval_frame_end = Date.parse("#{3.years.from_now}-12-31")
occurrences = event.occurrences_between(interval_frame_start, interval_frame_end)
if occurrences.present?
occurrences.each do |occurrence|
@ -247,8 +247,8 @@ returns
end
end
end
next if event.dtstart < Time.zone.now - 1.year
next if event.dtstart > Time.zone.now + 3.years
next if event.dtstart < 1.year.ago
next if event.dtstart > 3.years.from_now
result = Calendar.day_and_comment_by_event(event, event.dtstart)
next if !result

View file

@ -225,7 +225,7 @@ with dedicated times
=end
def self.cleanup(max_age = Time.zone.now - 9.months, max_own_seen = 10.minutes.ago, max_auto_seen = 8.hours.ago)
def self.cleanup(max_age = 9.months.ago, max_own_seen = 10.minutes.ago, max_auto_seen = 8.hours.ago)
OnlineNotification.where('created_at < ?', max_age).delete_all
OnlineNotification.where('seen = ? AND updated_at < ?', true, max_own_seen).each do |notification|

View file

@ -560,8 +560,8 @@ class OnlineNotificationTest < ActiveSupport::TestCase
user_id: @agent_user1.id,
created_by_id: 1,
updated_by_id: 1,
created_at: Time.zone.now - 10.months,
updated_at: Time.zone.now - 10.months,
created_at: 10.months.ago,
updated_at: 10.months.ago,
)
online_notification2 = OnlineNotification.add(
type: 'create',
@ -571,8 +571,8 @@ class OnlineNotificationTest < ActiveSupport::TestCase
user_id: @agent_user1.id,
created_by_id: 1,
updated_by_id: 1,
created_at: Time.zone.now - 10.months,
updated_at: Time.zone.now - 10.months,
created_at: 10.months.ago,
updated_at: 10.months.ago,
)
online_notification3 = OnlineNotification.add(
type: 'create',
@ -652,8 +652,8 @@ class OnlineNotificationTest < ActiveSupport::TestCase
user_id: @agent_user1.id,
created_by_id: 1,
updated_by_id: 1,
created_at: Time.zone.now - 10.months,
updated_at: Time.zone.now - 10.months,
created_at: 10.months.ago,
updated_at: 10.months.ago,
)
end
assert_raises(ActiveRecord::RecordNotFound) do
@ -665,8 +665,8 @@ class OnlineNotificationTest < ActiveSupport::TestCase
user_id: @agent_user1.id,
created_by_id: 1,
updated_by_id: 1,
created_at: Time.zone.now - 10.months,
updated_at: Time.zone.now - 10.months,
created_at: 10.months.ago,
updated_at: 10.months.ago,
)
end
end