From dae1f313e43830392b183f00ec741f61d68b826f Mon Sep 17 00:00:00 2001 From: John van Breda Date: Tue, 5 Feb 2019 13:59:01 +0000 Subject: [PATCH] Fixes conversion of snake to camelCase for method names --- modules/rest_api/controllers/services/rest.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/rest_api/controllers/services/rest.php b/modules/rest_api/controllers/services/rest.php index 1cd215f83a..443ea92fd1 100644 --- a/modules/rest_api/controllers/services/rest.php +++ b/modules/rest_api/controllers/services/rest.php @@ -639,8 +639,7 @@ public function __call($name, $arguments) { elseif ($this->method === 'POST') { $this->request = $_POST; } - - $methodName = lcfirst(ucwords($name, '-')) . ucfirst(strtolower($this->method)); + $methodName = lcfirst(str_replace('_', '', ucwords($name, '_'))) . ucfirst(strtolower($this->method)); $this->checkVersion($arguments); $requestForId = NULL;