summaryrefslogtreecommitdiff
path: root/lib/kolab_api_service.php
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2012-05-22 16:37:01 (GMT)
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2012-05-22 16:37:01 (GMT)
commit2a8ca12da53edb731b893b61bbcc0aad81396e7c (patch)
treed4ccd81e84a71e4fe3dc8b25c54a5f7d4f688f58 /lib/kolab_api_service.php
parent521b6a5d90eba76fb7ea43754915ae0793b77349 (diff)
downloadkolab-wap-2a8ca12da53edb731b893b61bbcc0aad81396e7c.tar.gz
Add 'resource' as a valid type
Diffstat (limited to 'lib/kolab_api_service.php')
-rw-r--r--lib/kolab_api_service.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/kolab_api_service.php b/lib/kolab_api_service.php
index 8c9dbde..18e6e82 100644
--- a/lib/kolab_api_service.php
+++ b/lib/kolab_api_service.php
@@ -59,7 +59,7 @@ abstract class kolab_api_service
*/
protected function object_type_attributes($object_name, $type_id, $required = true)
{
- $supported = array('domain', 'group', 'role', 'user');
+ $supported = array('domain', 'group', 'resource', 'role', 'user');
if (!$object_name || !in_array($object_name, $supported)) {
return array();
}
@@ -165,11 +165,12 @@ abstract class kolab_api_service
*/
protected function object_types($object_name)
{
- $supported = array('group', 'user');
+ $supported = array('group', 'resource', 'user');
if (!$object_name || !in_array($object_name, $supported)) {
return array();
}
+
if (!empty($this->cache['object_types']) && !empty($this->cache['object_types'][$object_name])) {
return $this->cache['object_types'][$object_name];
}
@@ -198,7 +199,12 @@ abstract class kolab_api_service
}
}
+ //console("Object types for " . $object_name, $object_types);
+
+// return $object_types;
+
return $this->cache['object_types'][$object_name] = $object_types;
+
}
/**