summaryrefslogtreecommitdiffstats
path: root/lib/api/kolab_api_service_user.php
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-04-18 15:33:38 +0200
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-04-18 15:33:38 +0200
commita5f265e17831b38d4a956feaefad909f9899d689 (patch)
treefc31f6182a4ecded8382935c3d20961bec30bf31 /lib/api/kolab_api_service_user.php
parentdba00f1f7c20cf3130d32070fd06603485b4916a (diff)
downloadwebadmin-a5f265e17831b38d4a956feaefad909f9899d689.tar.gz
Make the API parameters more consistent, and therefore easier to document
Diffstat (limited to 'lib/api/kolab_api_service_user.php')
-rw-r--r--lib/api/kolab_api_service_user.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/api/kolab_api_service_user.php b/lib/api/kolab_api_service_user.php
index ffe6637..9e4cdde 100644
--- a/lib/api/kolab_api_service_user.php
+++ b/lib/api/kolab_api_service_user.php
@@ -106,13 +106,13 @@ class kolab_api_service_user extends kolab_api_service
public function user_delete($getdata, $postdata)
{
//console("user_delete()", $getdata, $postdata);
- if (!isset($postdata['user'])) {
+ if (!isset($postdata['id'])) {
return false;
}
// TODO: Input validation
$auth = Auth::get_instance();
- $result = $auth->user_delete($postdata['user']);
+ $result = $auth->user_delete($postdata['id']);
if ($result) {
return $result;
@@ -145,7 +145,7 @@ class kolab_api_service_user extends kolab_api_service
public function user_effective_rights($getdata, $postdata)
{
$auth = Auth::get_instance();
- $effective_rights = $auth->list_rights(empty($getdata['user']) ? 'user' : $getdata['user']);
+ $effective_rights = $auth->list_rights(empty($getdata['id']) ? 'user' : $getdata['id']);
return $effective_rights;
}
@@ -159,18 +159,18 @@ class kolab_api_service_user extends kolab_api_service
*/
public function user_info($getdata, $postdata)
{
- if (!isset($getdata['user'])) {
+ if (!isset($getdata['id'])) {
return false;
}
$auth = Auth::get_instance();
- $result = $auth->user_info($getdata['user']);
+ $result = $auth->user_info($getdata['id']);
- Log::trace("user.info on " . $getdata['user'] . " result: " . var_export($result, TRUE));
+ Log::trace("user.info on " . $getdata['id'] . " result: " . var_export($result, TRUE));
// normalize result
$result = $this->parse_result_attributes('user', $result);
- Log::trace("user.info on " . $getdata['user'] . " parsed result: " . var_export($result, TRUE));
+ Log::trace("user.info on " . $getdata['id'] . " parsed result: " . var_export($result, TRUE));
if ($result) {
return $result;