Skip to content

Commit 1d2d16e

Browse files
authored
Declare conditional return types in Auth
1 parent c3b26d4 commit 1d2d16e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/Saml2/Auth.php

+3
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,7 @@ public function processResponse($requestId = null)
246246
* @param bool $stay True if we want to stay (returns the url string) False to redirect
247247
*
248248
* @return string|null
249+
* @phpstan-return ($stay is true ? string : never)
249250
*
250251
* @throws OneLogin_Saml2_Error
251252
*/
@@ -498,6 +499,7 @@ public function getAttributeWithFriendlyName($friendlyName)
498499
* @param string $nameIdValueReq Indicates to the IdP the subject that should be authenticated
499500
*
500501
* @return string|null If $stay is True, it return a string with the SLO URL + LogoutRequest + parameters
502+
* @phpstan-return ($stay is true ? string : never)
501503
*
502504
* @throws OneLogin_Saml2_Error
503505
*/
@@ -540,6 +542,7 @@ public function login($returnTo = null, $parameters = array(), $forceAuthn = fal
540542
* @param string|null $nameIdNameQualifier The NameID NameQualifier will be set in the LogoutRequest.
541543
*
542544
* @return string|null If $stay is True, it return a string with the SLO URL + LogoutRequest + parameters
545+
* @phpstan-return ($stay is true ? string : never)
543546
*
544547
* @throws OneLogin_Saml2_Error
545548
*/

0 commit comments

Comments
 (0)