Skip to content

Commit c293574

Browse files
committed
Revert f2c22b 72faad
1 parent 8ac2fb7 commit c293574

1 file changed

Lines changed: 2 additions & 10 deletions

File tree

app/services/school_verification_service.rb

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,8 @@ def verify(token: nil)
1212
School.transaction do
1313
school.verify!
1414

15-
if FeatureFlags.immediate_school_onboarding?
16-
# For backwards compatibility with pre-Immediate Onboarding unverified schools, we need to create the roles
17-
# if they don't exist - this didn't happen at the time the school was created.
18-
creator_id = school.creator_id
19-
Role.owner.find_or_create_by!(user_id: creator_id, school:)
20-
Role.teacher.find_or_create_by!(user_id: creator_id, school:)
21-
success = true
22-
else
23-
success = SchoolOnboardingService.new(school).onboard(token: token)
24-
end
15+
# TODO: Remove this line, once the feature flag is retired
16+
success = FeatureFlags.immediate_school_onboarding? || SchoolOnboardingService.new(school).onboard(token: token)
2517

2618
# TODO: Remove this line, once the feature flag is retired
2719
raise ActiveRecord::Rollback unless success

0 commit comments

Comments
 (0)