aboutsummaryrefslogtreecommitdiffstats
path: root/include/ws_functions.inc.php
diff options
context:
space:
mode:
authormistic100 <mistic@piwigo.org>2012-06-20 15:56:54 +0000
committermistic100 <mistic@piwigo.org>2012-06-20 15:56:54 +0000
commitc8d097d3f86b9595e52bf754a2bcc2427593692e (patch)
tree5728699a7b85b60155ab63bd1f73ad1381500934 /include/ws_functions.inc.php
parent07c7470584c11c2a20792f123299c79aebcad6da (diff)
feature 2657: make sure admins can access the new category (see r11727)
git-svn-id: http://piwigo.org/svn/trunk@15851 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'include/ws_functions.inc.php')
-rw-r--r--include/ws_functions.inc.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/ws_functions.inc.php b/include/ws_functions.inc.php
index f628cf520..7f587f6ac 100644
--- a/include/ws_functions.inc.php
+++ b/include/ws_functions.inc.php
@@ -2307,6 +2307,11 @@ function ws_categories_add($params, &$service)
if ( !empty($params['status']) and in_array($params['status'], array('private','public')) )
{
$updates['status'] = $params['status'];
+
+ if ('private' == $updates['status'])
+ {
+ add_permission_on_category($creation_output['id'], get_admins());
+ }
}
if ( !empty($params['visible']) and in_array($params['visible'], array('true','false')) )
{