MDL-12886 adding killswitch for webservices
This commit is contained in:
@@ -15,6 +15,10 @@
|
||||
require_once(dirname(dirname(dirname(__FILE__))) . '/config.php');
|
||||
require_once('lib.php');
|
||||
|
||||
if (empty($CFG->enablewebservices)) {
|
||||
die;
|
||||
}
|
||||
|
||||
//retrieve path and function name from the URL
|
||||
$rest_arguments = get_file_argument('server.php');
|
||||
|
||||
|
||||
@@ -12,6 +12,11 @@
|
||||
|
||||
require_once("../../../config.php");
|
||||
require_once ('lib.php');
|
||||
|
||||
if (empty($CFG->enablewebservices)) {
|
||||
die;
|
||||
}
|
||||
|
||||
$CFG->serverurl = $CFG->wwwroot.'/webservice/rest/server.php';
|
||||
if (!function_exists('curl_init')) die ('CURL library was not found!');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user