1. 01 9月, 2017 1 次提交
    • M
      Clarify intentions around method redefinitions · 2e6658ae
      Matthew Draper 提交于
      Don't use remove_method or remove_possible_method just before a new
      definition: at best the purpose is unclear, and at worst it creates a
      race condition.
      
      Instead, prefer redefine_method when practical, and
      silence_redefinition_of_method otherwise.
      2e6658ae
  2. 29 7月, 2017 1 次提交
  3. 02 7月, 2017 1 次提交
  4. 01 7月, 2017 1 次提交
  5. 30 5月, 2017 1 次提交
  6. 27 12月, 2016 1 次提交
  7. 01 10月, 2016 1 次提交
  8. 07 8月, 2016 2 次提交
  9. 05 5月, 2016 1 次提交
  10. 09 1月, 2016 1 次提交
  11. 04 1月, 2016 2 次提交
  12. 01 1月, 2016 1 次提交
  13. 07 10月, 2015 1 次提交
    • J
      Use `Mime[:foo]` instead of `Mime::Type[:FOO]` for back compat · 565094a8
      Jeremy Daer 提交于
      Rails 4.x and earlier didn't support `Mime::Type[:FOO]`, so libraries
      that support multiple Rails versions would've had to feature-detect
      whether to use `Mime::Type[:FOO]` or `Mime::FOO`.
      
      `Mime[:foo]` has been around for ages to look up registered MIME types
      by symbol / extension, though, so libraries and plugins can safely
      switch to that without breaking backward- or forward-compatibility.
      
      Note: `Mime::ALL` isn't a real MIME type and isn't registered for lookup
      by type or extension, so it's not available as `Mime[:all]`. We use it
      internally as a wildcard for `respond_to` negotiation. If you use this
      internal constant, continue to reference it with `Mime::ALL`.
      
      Ref. efc6dd55
      565094a8
  14. 22 9月, 2015 1 次提交
  15. 12 7月, 2015 1 次提交
  16. 06 11月, 2014 1 次提交
  17. 04 9月, 2014 1 次提交
    • X
      code gardening in ActionController::Renderers · 4dfe140e
      Xavier Noria 提交于
      * Renames _handle_render_options to _render_to_body_with_renderer, which is more
        intention-revealing.
      
      * The name of the dynamically generated method for a renderer with key :js was
        "_render_option_js".
      
        That name is too weak. :js is an option if you see the render argument as just
        a generic options hash, but in the context of renderers that's the renderer
        key, is what identifies the renderer.
      
        Now "_render_with_renderer_js" is generated instead, which is crystal clear.
      
      * The name of the dynamically generated method for the renderer was constructed
        using string literals in a few places. That is now encapsulated in a method.
      
      * Since we were on it, also removed a couple of redundant selfs.
      4dfe140e
  18. 10 7月, 2014 1 次提交
  19. 03 7月, 2014 1 次提交
  20. 26 5月, 2014 1 次提交
  21. 20 5月, 2014 1 次提交
  22. 21 4月, 2014 1 次提交
  23. 26 12月, 2013 1 次提交
  24. 06 9月, 2013 1 次提交
  25. 18 8月, 2013 1 次提交
    • B
      Fail informatively in #respond_with when no appropriate #api_behavior renderer is available. · f84c6201
      Ben Woosley 提交于
      Currently if a user calls #respond_with(csvable), but has not csv
      renderer available, Responder will just run through the default render
      behavior twice, raising ActionView::MissingTemplate both times.
      
      This changes ActionController::Metal::Responder#api_behavior to check
      in advance whether there is a renderer available, and raise
      ActionController::MissingRenderer if not.
      f84c6201
  26. 28 10月, 2012 1 次提交
  27. 03 8月, 2012 2 次提交
  28. 15 5月, 2012 1 次提交
  29. 29 4月, 2012 1 次提交
  30. 16 10月, 2011 1 次提交
  31. 28 7月, 2011 1 次提交
  32. 18 4月, 2011 1 次提交
  33. 13 4月, 2011 1 次提交
  34. 10 2月, 2011 1 次提交
  35. 25 11月, 2010 1 次提交
  36. 23 11月, 2010 2 次提交