Stylistic change on System mappings

This commit is contained in:
Mitchell Hashimoto 2011-01-09 13:10:52 -08:00
parent 6c57154dac
commit 272b421e0b
1 changed files with 5 additions and 1 deletions

View File

@ -57,7 +57,11 @@ module Vagrant
raise Errors::VMSystemError, :_key => :invalid_class, :system => system.to_s if !@system.is_a?(Systems::Base)
elsif system.is_a?(Symbol)
# Hard-coded internal systems
mapping = { :linux => Systems::Linux, :solaris => Systems::Solaris, :gentoo => Systems::Gentoo }
mapping = {
:linux => Systems::Linux,
:solaris => Systems::Solaris,
:gentoo => Systems::Gentoo
}
raise Errors::VMSystemError, :_key => :unknown_type, :system => system.to_s if !mapping.has_key?(system)
@system = mapping[system].new(self)