MDL-46753 auth_cas: Replace hardcoded logout_return_url to user defined URL.

Credit goes to Mitsuru Udagawa, thanks!
This commit is contained in:
Simey Lameze
2014-08-18 12:51:44 +08:00
parent e1eb180806
commit 71ec01afa6
+1 -1
View File
@@ -509,7 +509,7 @@ class auth_plugin_cas extends auth_plugin_ldap {
global $CFG;
// Only redirect to CAS logout if the user is logged as a CAS user.
if (!empty($this->config->logoutcas) && $user->auth == $this->authtype) {
$backurl = $CFG->wwwroot;
$backurl = !empty($this->config->logout_return_url) ? $this->config->logout_return_url : $CFG->wwwroot;
$this->connectCAS();
phpCAS::logoutWithRedirectService($backurl);
}