Class: Typekit::Processing::Translator

Inherits:
Object
  • Object
show all
Defined in:
lib/typekit/processing/translator.rb

Instance Method Summary collapse

Instance Method Details

#process(result) ⇒ Object



4
5
6
7
8
9
10
# File 'lib/typekit/processing/translator.rb', line 4

def process(result)
  unless result.is_a?(Hash) && result.length == 1
    raise Error, 'Unknown server response'
  end
  name, object = *result.first
  Converter.build(name).process(result, object)
end