like we do in other apis of section configs (e.g. storage) Signed-off-by: Dominik Csapak <d.csa...@proxmox.com> --- PVE/API2/Cluster/MetricServer.pm | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/PVE/API2/Cluster/MetricServer.pm b/PVE/API2/Cluster/MetricServer.pm index 9a14985e..ec3c7b75 100644 --- a/PVE/API2/Cluster/MetricServer.pm +++ b/PVE/API2/Cluster/MetricServer.pm @@ -213,6 +213,8 @@ __PACKAGE__->register_method ({ my $d = $options->{$k} || die "no such option '$k'\n"; die "unable to delete required option '$k'\n" if !$d->{optional}; die "unable to delete fixed option '$k'\n" if $d->{fixed}; + die "cannot set and delete property '$k' at the same time!\n" + if defined($opts->{$k}); delete $data->{$k}; } -- 2.20.1 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel