Skip to content
Snippets Groups Projects
Commit 2d9fdf71 authored by Jaime Perez Crespo's avatar Jaime Perez Crespo
Browse files

Move SimpleSAML_Auth_Default::logoutCompleted() to SimpleSAML_Auth_Source and deprecate the former.

parent 96bb5ad6
Branches
Tags
No related merge requests found
......@@ -105,20 +105,10 @@ class SimpleSAML_Auth_Default {
/**
* Called when logout operation completes.
*
* This function never returns.
*
* @param array $state The state after the logout.
* @deprecated This method will be removed in SSP 2.0. Please use SimpleSAML_Auth_Source::logoutCompleted() instead.
*/
public static function logoutCompleted($state) {
assert('is_array($state)');
assert('array_key_exists("SimpleSAML_Auth_Default.ReturnURL", $state)');
$returnURL = $state['SimpleSAML_Auth_Default.ReturnURL'];
/* Redirect... */
\SimpleSAML\Utils\HTTP::redirectTrustedURL($returnURL);
SimpleSAML_Auth_Source::logoutCompleted($state);
}
......
......@@ -247,6 +247,22 @@ abstract class SimpleSAML_Auth_Source
}
/**
* Called when logout operation completes.
*
* This function never returns.
*
* @param array $state The state after the logout.
*/
public static function logoutCompleted($state)
{
assert('is_array($state)');
assert('array_key_exists("SimpleSAML_Auth_Default.ReturnURL", $state)');
\SimpleSAML\Utils\HTTP::redirectTrustedURL($state['SimpleSAML_Auth_Default.ReturnURL']);
}
/**
* Complete logout.
*
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment