feature 2657: previous commit may work, but badly coded
git-svn-id: http://piwigo.org/svn/trunk@15852 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
parent
c8d097d3f8
commit
6ddf16ead6
1 changed files with 5 additions and 5 deletions
|
@ -2307,11 +2307,6 @@ 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')) )
|
||||
{
|
||||
|
@ -2334,6 +2329,11 @@ function ws_categories_add($params, &$service)
|
|||
array('id'=>$creation_output['id'])
|
||||
);
|
||||
}
|
||||
|
||||
if ( isset($updates['status']) and 'private' == $updates['status'] )
|
||||
{
|
||||
add_permission_on_category($creation_output['id'], get_admins());
|
||||
}
|
||||
|
||||
invalidate_user_cache();
|
||||
|
||||
|
|
Loading…
Reference in a new issue