From 7bb0eb81928f4a3a0f15da3691e9133e5b0ba541 Mon Sep 17 00:00:00 2001 From: Sandor Semsey Date: Fri, 6 May 2022 13:03:19 +0200 Subject: [PATCH] dev/drupal#179 - kcfinder - Explicit start of Drupal session --- kcfinder/integration/civicrm.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/kcfinder/integration/civicrm.php b/kcfinder/integration/civicrm.php index dccf72c71..b511535fe 100644 --- a/kcfinder/integration/civicrm.php +++ b/kcfinder/integration/civicrm.php @@ -104,6 +104,10 @@ function authenticate_drupal8($config) { } } } + + // Start Drupal's own session now, so changes to $_SESSION won't get overwritten later + \Drupal::service('session')->start(); + // check if user has access permission... if (CRM_Core_Permission::check('access CiviCRM')) { return true;