X-Git-Url: https://git.proxmox.com/?p=pve-common.git;a=blobdiff_plain;f=src%2FPVE%2FJSONSchema.pm;fp=src%2FPVE%2FJSONSchema.pm;h=e8d7395a858619a13668d5a570671f57198803a7;hp=2ceb1bd7aaac47019d1929a98706d487ab86ce46;hb=3fe29ce6c9f7c94837fefba44f180feab7f93efb;hpb=a24d91ea089a71eb07ece8ab2d7d286fa833393a diff --git a/src/PVE/JSONSchema.pm b/src/PVE/JSONSchema.pm index 2ceb1bd..e8d7395 100644 --- a/src/PVE/JSONSchema.pm +++ b/src/PVE/JSONSchema.pm @@ -1644,7 +1644,7 @@ sub get_options { foreach my $arg_name (@$arg_param) { if ($arg_name eq 'extra-args') { $opts->{'extra-args'} = []; - } else { + } elsif (!$schema->{properties}->{$arg_name}->{optional}) { raise("not enough arguments\n", code => HTTP_BAD_REQUEST); } }