Skip to content

Commit 8956fca

Browse files
committed
Fix create_default_programme_year_groups task
We need to run this task after deploying 2.11 to production and it looks like a refactor since the task was initially created and run in the test environment has broken it. This fixes the Rake task to run correctly. This task doesn't have any tests as it's a one off task that will be run after a deploy and then deleted, it's been run in test and QA successfully.
1 parent afe76aa commit 8956fca

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/tasks/create_default_programme_year_groups.rake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ task create_default_programme_year_groups: :environment do
99
organisation.programmes.flat_map(&:default_year_groups).uniq.sort
1010

1111
organisation.locations.generic_clinic.find_each do |generic_clinic|
12-
generic_clinic.update_all(year_groups:)
12+
generic_clinic.update!(year_groups:)
1313
generic_clinic.create_default_programme_year_groups!(
1414
organisation.programmes
1515
)

0 commit comments

Comments
 (0)