File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff 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
You can’t perform that action at this time.
0 commit comments