From a8e2ad5b743d0556258ccfeef02b101efeb6ae4b Mon Sep 17 00:00:00 2001 From: Nigel McNie Date: Thu, 10 Jan 2008 09:37:02 +1300 Subject: [PATCH] Moodle's XMLRPC API currently makes some calls that Mahara doesn't implement. Implement these calls as no-ops. --- htdocs/api/xmlrpc/dispatcher.php | 7 +++++-- htdocs/api/xmlrpc/lib.php | 4 ++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/htdocs/api/xmlrpc/dispatcher.php b/htdocs/api/xmlrpc/dispatcher.php index f2e756fc..27870aeb 100644 --- a/htdocs/api/xmlrpc/dispatcher.php +++ b/htdocs/api/xmlrpc/dispatcher.php @@ -47,7 +47,10 @@ class Dispatcher { 'sso_in' => array(), 'sso_out' =>array( 'auth/mnet/auth.php/user_authorise' => 'user_authorise', - 'auth/mnet/auth.php/fetch_user_image' => 'fetch_user_image' + 'auth/mnet/auth.php/fetch_user_image' => 'fetch_user_image', + 'auth/mnet/auth.php/update_enrolments' => 'xmlrpc_not_implemented', + 'auth/mnet/auth.php/keepalive_server' => 'xmlrpc_not_implemented', + 'auth/mnet/auth.php/kill_children' => 'xmlrpc_not_implemented', ) ); @@ -136,7 +139,7 @@ class Dispatcher { } } - throw new XmlrpcServerException('No such method'); + throw new XmlrpcServerException('No such method: ' . $this->method); } diff --git a/htdocs/api/xmlrpc/lib.php b/htdocs/api/xmlrpc/lib.php index 450e1a04..26bacf68 100644 --- a/htdocs/api/xmlrpc/lib.php +++ b/htdocs/api/xmlrpc/lib.php @@ -260,6 +260,10 @@ function user_authorise($token, $useragent) { return $userdata; } +function xmlrpc_not_implemented() { + return true; +} + /** * Given a USER, get all Service Providers for that User, based on child auth * instances of its canonical auth instance -- GitLab