Class: DefaultTranslator

Inherits:
Translator show all
Includes:
Singleton
Defined in:
lib/translator.rb

Constant Summary

Constants inherited from Translator

Translator::LANG_BREAK

Instance Method Summary collapse

Methods inherited from Translator

default, for

Instance Method Details

#localize(text) ⇒ Object



26
27
28
29
30
# File 'lib/translator.rb', line 26

def localize(text)
  md = text.match(LANG_BREAK)
  return md.pre_match unless md.nil?
  return text
end