Don't allow public accesslist creation via API
This commit is contained in:
parent
8f824b84d7
commit
f04e4bff33
|
@ -11,6 +11,3 @@ properties:
|
|||
type: integer
|
||||
minimum: 0
|
||||
maximum: 255
|
||||
is_public:
|
||||
description: The visibility of the new accesslist. Default is false (private).
|
||||
type: boolean
|
||||
|
|
|
@ -53,9 +53,6 @@ paths:
|
|||
type: integer
|
||||
minimum: 0
|
||||
maximum: 255
|
||||
is_public:
|
||||
description: The visibility of the new accesslist. Default is false (private).
|
||||
type: boolean
|
||||
responses:
|
||||
"200":
|
||||
description: The id of the newly created accesslist.
|
||||
|
|
|
@ -10,7 +10,4 @@ properties:
|
|||
description: Sort order for the new accesslist, 0 to 255.
|
||||
type: integer
|
||||
minimum: 0
|
||||
maximum: 255
|
||||
is_public:
|
||||
description: The visibility of the new accesslist. Default is false (private).
|
||||
type: boolean
|
||||
maximum: 255
|
|
@ -62,13 +62,11 @@ sub accesslists_new {
|
|||
return $self->rest_error("403") unless $user == $remote;
|
||||
|
||||
my $body = $args->{body};
|
||||
$body->{is_public} ||= 0; #default false
|
||||
$body->{sortorder} ||= 0;
|
||||
|
||||
my $group = $user->create_trust_group(
|
||||
groupname => $body->{name},
|
||||
sortorder => $body->{sortorder},
|
||||
is_public => $body->{is_public}
|
||||
sortorder => $body->{sortorder}
|
||||
);
|
||||
|
||||
return $self->rest_ok( { id => $group } );
|
||||
|
|
Loading…
Reference in New Issue