Skip to content
Snippets Groups Projects
Commit 88f59e06 authored by Thijs Kinkhorst's avatar Thijs Kinkhorst
Browse files

Default value to getArrayizeString must also be array if we want to prevent PHP notices

parent 4b581b8b
No related branches found
No related tags found
No related merge requests found
......@@ -1004,9 +1004,9 @@ class SAML2
if ($nameIdFormat === null || !isset($state['saml:NameID'][$nameIdFormat])) {
// either not set in request, or not set to a format we supply. Fall back to old generation method
$nameIdFormat = current($spMetadata->getArrayizeString('NameIDFormat', null));
$nameIdFormat = current($spMetadata->getArrayizeString('NameIDFormat', []));
if ($nameIdFormat === null) {
$nameIdFormat = current($idpMetadata->getArrayizeString('NameIDFormat', \SAML2\Constants::NAMEID_TRANSIENT));
$nameIdFormat = current($idpMetadata->getArrayizeString('NameIDFormat', [\SAML2\Constants::NAMEID_TRANSIENT]));
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment