1. 05 4月, 2015 1 次提交
    • A
      Allow an array to be a default translation value. · 6f3c65f6
      Adam Prescott 提交于
      4.2.1 introduced a change to the way `translate`/`t` works with an
      option of `default: [[]]`. In 4.2.0, this would give a default value of
      `[]`, but in 4.2.1, it leads to a missing translation.
      
      `default: [[]]` is again allowed for cases where a default of `[]` is
      needed.
      
      This addresses GitHub issue 19640.
      6f3c65f6
  2. 21 3月, 2015 1 次提交
  3. 27 2月, 2015 1 次提交
    • U
      Fix regression when passing a value different of String. · 362557eb
      Ulisses Almeida 提交于
      The previous version of rails(4.2.0) you can pass objects
      to the default option of translation helper.
      
      For example:
      
      ```ruby
        t('foo', default: 1)
      ```
      
      But on rails 4.2.1 version this kind of use stopped to work,
      because started only to accept String types.
      
      Now with this fix we can use orther value types on this
      helper again.
      362557eb
  4. 03 1月, 2015 1 次提交
  5. 19 11月, 2014 1 次提交
  6. 06 9月, 2014 1 次提交
  7. 14 8月, 2014 1 次提交
  8. 13 5月, 2014 2 次提交
  9. 27 1月, 2014 1 次提交
  10. 05 12月, 2013 1 次提交
    • S
      Escalate missing error when :raise is true · c1d5477b
      Shota Fukumori (sora_h) 提交于
      Before ec16ba75,
      ActionView::Helpers::TranslationHelper#translate has raised errors with
      specifying options[:raise] to true.
      
      This should work by this fix:
      
           begin
             t(:"translations.missing", raise: true)
           rescue I18n::MissingTranslationData
             p :hello!
           end
      c1d5477b
  11. 03 12月, 2013 1 次提交
    • M
      Stop using i18n's built in HTML error handling. · 0c7ac34a
      Michael Koziarski 提交于
      i18n doesn't depend on active support which means it can't use our html_safe
      code to do its escaping when generating the spans.  Rather than try to sanitize
      the output from i18n, just revert to our old behaviour of rescuing the error
      and constructing the tag ourselves.
      
      Fixes: CVE-2013-4491
      0c7ac34a
  12. 20 6月, 2013 1 次提交
  13. 29 10月, 2012 1 次提交
  14. 23 5月, 2012 1 次提交
    • P
      Fixed typo new_defautls -> new_defaults. · 40c0b3a2
      Philip Arndt 提交于
      * Added tests for 'else' case in ActionView::Helpers::TranslationHelper#wrap_translate_defaults
      * Also updated the testing syntax of translation.html_safe? asserts to provide better output upon failure.
      40c0b3a2
  15. 05 5月, 2012 1 次提交
  16. 30 4月, 2012 1 次提交
  17. 19 11月, 2011 1 次提交
  18. 18 11月, 2011 3 次提交
  19. 23 7月, 2011 1 次提交
  20. 15 6月, 2011 2 次提交
  21. 11 5月, 2011 1 次提交
  22. 01 5月, 2011 1 次提交
  23. 26 4月, 2011 1 次提交
  24. 05 3月, 2011 1 次提交
  25. 04 3月, 2011 1 次提交
  26. 05 12月, 2010 3 次提交
  27. 10 10月, 2010 1 次提交
  28. 14 8月, 2010 2 次提交
  29. 17 6月, 2010 1 次提交
  30. 11 6月, 2010 1 次提交
  31. 25 5月, 2010 3 次提交