From 8fba27181765dc18bb271f0d1b2e11ffece753c7 Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Thu, 26 Jan 2012 11:55:28 +0100 Subject: [PATCH] moved format definition to pve-common --- PVE/Storage.pm | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/PVE/Storage.pm b/PVE/Storage.pm index c30d37a..9ab6f7d 100755 --- a/PVE/Storage.pm +++ b/PVE/Storage.pm @@ -933,23 +933,6 @@ sub iscsi_device_list { # library implementation - -PVE::JSONSchema::register_format('pve-storage-id', \&parse_storage_id); -sub parse_storage_id { - my ($storeid, $noerr) = @_; - - if ($storeid !~ m/^[a-z][a-z0-9\-\_\.]*[a-z0-9]$/i) { - return undef if $noerr; - die "storage ID '$storeid' contains illegal characters\n"; - } - return $storeid; -} - -PVE::JSONSchema::register_standard_option('pve-storage-id', { - description => "The storage identifier.", - type => 'string', format => 'pve-storage-id', -}); - PVE::JSONSchema::register_format('pve-storage-vgname', \&parse_lvm_name); sub parse_lvm_name { my ($name, $noerr) = @_;