diff --git a/src/Subfission/Cas/CasManager.php b/src/Subfission/Cas/CasManager.php index 56d87a4..9231666 100644 --- a/src/Subfission/Cas/CasManager.php +++ b/src/Subfission/Cas/CasManager.php @@ -177,6 +177,15 @@ protected function parseConfig(array $config) 'cas_real_hosts' => '', ]; + /* + * If cas_client_service is a string, see if it contains a comma and split on it. + * Only do this when it looks like we have a comma separated list. Passing in an array + * triggers autodiscovery downstream and we want to avoid that if possible. + */ + if (is_string($config['cas_client_service']) && strpos($config['cas_client_service'], ',') !== false) { + $config['cas_client_service'] = explode(',', $config['cas_client_service']); + } + $this->config = array_merge($defaults, $config); } diff --git a/src/config/config.php b/src/config/config.php index a58a98e..56b1754 100644 --- a/src/config/config.php +++ b/src/config/config.php @@ -65,7 +65,7 @@ |-------------------------------------------------------------------------- | Example: 'http://localhost', 'https://example.com:8888' */ - 'cas_client_service' => explode(',', env('CAS_CLIENT_SERVICE', 'http://localhost')), + 'cas_client_service' => env('CAS_CLIENT_SERVICE', 'http://localhost'), /*