1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-22 18:50:08 +03:00

Fix constant typo in VirtualNetwork

This commit is contained in:
Daniel Molina 2011-06-22 16:21:53 +02:00
parent 8cd7e6af58
commit 45be62f7a7
2 changed files with 6 additions and 6 deletions

View File

@ -27,8 +27,8 @@ class OneVNetHelper < OpenNebulaHelper::OneHelper
def self.type_to_str(id)
id = id.to_i
type_str = VirtualNetwork::VNET_TYPES[id]
return VirtualNetwork::SHORT_VNET_TYPES[type_str]
type_str = VirtualNetwork::VN_TYPES[id]
return VirtualNetwork::SHORT_VN_TYPES[type_str]
end
private

View File

@ -31,9 +31,9 @@ module OpenNebula
:chown => "vn.chown"
}
NETWORK_TYPES=%w{RANGED FIXED}
VN_TYPES=%w{RANGED FIXED}
SHORT_NETWORK_TYPES={
SHORT_VN_TYPES={
"RANGED" => "R",
"FIXED" => "F"
}
@ -144,12 +144,12 @@ module OpenNebula
# Returns the type of the Virtual Network (string value)
def type_str
NETWORK_TYPES[type]
VN_TYPES[type]
end
# Returns the state of the Virtual Network (string value)
def short_type_str
SHORT_NETWORK_TYPES[type_str]
SHORT_VN_TYPES[type_str]
end
private