summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJaime Perez Crespo <jaime.perez@uninett.no>2015-08-30 21:31:03 +0200
committerJaime Perez Crespo <jaime.perez@uninett.no>2015-08-30 21:31:03 +0200
commit2d9fdf714955e3b4fca7da392638c7dbebd9bf05 (patch)
tree183273d20b47d4796fdfef012379102f8d5960cd
parent96bb5ad68c7bbd876cc49b41cbcd27045b7c8e46 (diff)
downloadsimplesamlphp-2d9fdf714955e3b4fca7da392638c7dbebd9bf05.zip
simplesamlphp-2d9fdf714955e3b4fca7da392638c7dbebd9bf05.tar.gz
simplesamlphp-2d9fdf714955e3b4fca7da392638c7dbebd9bf05.tar.bz2
Move SimpleSAML_Auth_Default::logoutCompleted() to SimpleSAML_Auth_Source and deprecate the former.
-rw-r--r--lib/SimpleSAML/Auth/Default.php14
-rw-r--r--lib/SimpleSAML/Auth/Source.php16
2 files changed, 18 insertions, 12 deletions
diff --git a/lib/SimpleSAML/Auth/Default.php b/lib/SimpleSAML/Auth/Default.php
index 2d7a3d3..8298c4d 100644
--- a/lib/SimpleSAML/Auth/Default.php
+++ b/lib/SimpleSAML/Auth/Default.php
@@ -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);
}
diff --git a/lib/SimpleSAML/Auth/Source.php b/lib/SimpleSAML/Auth/Source.php
index 9009fb1..2ad82a7 100644
--- a/lib/SimpleSAML/Auth/Source.php
+++ b/lib/SimpleSAML/Auth/Source.php
@@ -248,6 +248,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.
*
* This function should be called after logout has completed. It will never return,