Module: Omniship::Base

Defined in:
lib/omniship/base.rb

Class Method Summary collapse

Class Method Details

.carrier(name) ⇒ Object



6
7
8
9
# File 'lib/omniship/base.rb', line 6

def self.carrier(name)
  Omniship::Carriers.all.find {|c| c.name.downcase == name.to_s.downcase} ||
    raise(NameError, "unknown carrier #{name}")
end