Skip to content

Commit

Permalink
fix: no method error && bump
Browse files Browse the repository at this point in the history
  • Loading branch information
Dim145 committed Apr 2, 2024
1 parent 5749ff1 commit 1a74890
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions app/controllers/parameters/planning_parameters_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ def index
end

current_season = Season.current
previous_season = current_season.previous

if @school.planning.time_intervals.where(start: current_season.start..current_season.end).empty?
previous_season = Season.previous
if previous_season.present? && @school.planning.time_intervals.where(start: current_season.start..current_season.end).empty?
school_availabilities = @school.planning.time_intervals.where(start: previous_season.start..previous_season.end).to_a

school_availabilities = school_availabilities.map do |availability|
Expand Down
2 changes: 1 addition & 1 deletion lib/elvis/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Elvis
VERSION = "2.2.10"
VERSION = "2.2.11"
end

0 comments on commit 1a74890

Please sign in to comment.