diff --git a/modules/os2forms_nemid/src/EventSubscriber/NemloginRedirectSubscriber.php b/modules/os2forms_nemid/src/EventSubscriber/NemloginRedirectSubscriber.php index 349d6974..3d69ffb9 100644 --- a/modules/os2forms_nemid/src/EventSubscriber/NemloginRedirectSubscriber.php +++ b/modules/os2forms_nemid/src/EventSubscriber/NemloginRedirectSubscriber.php @@ -172,6 +172,7 @@ public function redirectToNemlogin(RequestEvent $event) { if (!$authProviderPlugin->isAuthenticated()) { // Redirect directly to the external IdP. $response = new RedirectResponse($this->nemloginAuthProvider->getLoginUrl([], $authProviderPlugin->getPluginId())->toString()); + $event->setResponse($response); } else { $settingFormConfig = $this->configFactory->get(SettingsForm::$configName); diff --git a/scripts/code-analysis b/scripts/code-analysis index f8ace6c7..f8c3cc0b 100755 --- a/scripts/code-analysis +++ b/scripts/code-analysis @@ -11,9 +11,9 @@ drupal_composer() { composer --working-dir="$drupal_dir" --no-interaction "$@" } -# Create new Drupal 9 project +# Create new Drupal 10 project if [ ! -f "$drupal_dir/composer.json" ]; then - composer --no-interaction create-project drupal/recommended-project:^9 "$drupal_dir" + composer --no-interaction create-project drupal/recommended-project:^10 "$drupal_dir" fi # Copy our code into the modules folder mkdir -p "$drupal_dir/$module_path"