[pve-devel] [PATCH pve-common] print_property_string: skip undefined values

Wolfgang Bumiller w.bumiller at proxmox.com
Thu Oct 29 14:56:58 CET 2015


---
 src/PVE/JSONSchema.pm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/PVE/JSONSchema.pm b/src/PVE/JSONSchema.pm
index de2a0bd..e83d8de 100644
--- a/src/PVE/JSONSchema.pm
+++ b/src/PVE/JSONSchema.pm
@@ -588,6 +588,7 @@ sub print_property_string {
 
 	my $typeformat = $format->{$key}->{format};
 	my $value = $data->{$key};
+	next if !defined($value);
 	$text .= $comma;
 	$comma = ',';
 	if ($typeformat && $typeformat eq 'disk-size') {
-- 
2.1.4





More information about the pve-devel mailing list