webservice MDL-21579 $this->simple is now a DEFINE. Fix the forgotten ones.
This commit is contained in:
+1
-1
@@ -833,7 +833,7 @@ abstract class webservice_base_server extends webservice_server {
|
||||
* @return void
|
||||
*/
|
||||
protected function session_cleanup($exception=null) {
|
||||
if ($this->simple) {
|
||||
if ($this->authmethod == WEBSERVICE_AUTHMETHOD_USERNAME) {
|
||||
// nothing needs to be done, there is no persistent session
|
||||
} else {
|
||||
// close emulated session if used
|
||||
|
||||
@@ -48,7 +48,7 @@ class webservice_rest_server extends webservice_base_server {
|
||||
* @return void
|
||||
*/
|
||||
protected function parse_request() {
|
||||
if ($this->simple) {
|
||||
if ($this->authmethod == WEBSERVICE_AUTHMETHOD_USERNAME) {
|
||||
$this->username = isset($_REQUEST['wsusername']) ? $_REQUEST['wsusername'] : null;
|
||||
unset($_REQUEST['wsusername']);
|
||||
|
||||
|
||||
@@ -57,7 +57,7 @@ class webservice_soap_server extends webservice_zend_server {
|
||||
|
||||
parent::init_zend_server();
|
||||
|
||||
if ($this->simple) {
|
||||
if ($this->authmethod == WEBSERVICE_AUTHMETHOD_USERNAME) {
|
||||
$username = optional_param('wsusername', '', PARAM_RAW);
|
||||
$password = optional_param('wspassword', '', PARAM_RAW);
|
||||
// aparently some clients and zend soap server does not work well with "&" in urls :-(
|
||||
|
||||
Reference in New Issue
Block a user