]> git.proxmox.com Git - pve-access-control.git/commit - PVE/API2/Domains.pm
domain sync: make options actually required
authorDominik Csapak <d.csapak@proxmox.com>
Thu, 23 Apr 2020 06:47:17 +0000 (08:47 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Sat, 25 Apr 2020 16:31:35 +0000 (18:31 +0200)
commit055c54b5a20164d59c7288cc6a24f7ea2b597978
tree8374371f914d211035cbb7af06a811637aa52593
parent782b702dbbad6cb28db86f2701af76ded5813191
domain sync: make options actually required

we want the api options to be optional, but only as long as there are
default values set in the realm config

since they are all marked as optional (else they would be required in
the api) this check did not work as intended

instead, set the result to the value of:
* the parameter
* the set default in the config
* the api default
in this order

if it is undef after this, raise a parameter exception

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
PVE/API2/Domains.pm