1. 12 7月, 2016 2 次提交
  2. 11 7月, 2016 1 次提交
    • S
      Always prefer class types to query types when casting `group` · a45363a2
      Sean Griffin 提交于
      When `group` is used in combination with any calculation method, the
      resulting hash uses the grouping expression as the key. Currently we're
      incorrectly always favoring the type reported by the query, instead of
      the type known by the class. This causes differing behavior depending on
      whether the adaptor actually gives proper types with the query or not.
      After this change, the behavior will be the same on all adaptors -- we
      see if we know the type from the class, fall back to the type from the
      query, and finally fall back to the identity type.
      
      Fixes #25595
      a45363a2
  3. 09 7月, 2016 2 次提交
    • P
      Cleanup CHANGELOGs [ci skip] · 724b0833
      Prathamesh Sonpatki 提交于
      - Cleanup Active Record CHANGELOG.
      - Add missing CHANGELOG for https://github.com/rails/rails/pull/25688.
      - Clarify that assets requests logging is suppressed.
      724b0833
    • R
      fix to_param to maximize content · 3b49d792
      Rob Biedenharn 提交于
      The documentation states that parameter values longer than 20 characters
      will be truncated by words, but the example shows that a parameter based
      on "David Heinemeier Hansson" (with id: 125) becomes "125-david" when
      "David Heinemeier".length == 16 so why so short?
      
      The answer lies in the use of the #truncate option omission: nil which
      seems to have been intended to mean "nothing", but which actually causes
      the default string "..." to be used. This causes #truncate to cleave
      words until the "..." can be added and still remain within the requested
      size of 20 characters.
      
      The better option is omission: '' (which is probably what was originally
      intended).
      
      Furthermore, since the use of #parameterize will remove non-alphanumeric
      characters, we can maximize the useful content of the output by calling
      parameterize first and then giving truncate a separator: /-/ rather than
      a space.
      3b49d792
  4. 08 7月, 2016 1 次提交
  5. 06 7月, 2016 5 次提交
  6. 04 7月, 2016 3 次提交
  7. 03 7月, 2016 4 次提交
    • W
      Clarify Postgres initials. [skip ci] · b7f4b8e0
      William Johnston 提交于
      b7f4b8e0
    • B
      Improve error message when record touch fails. · ac156060
      Ben Standefer 提交于
      The current error message only indicates that a touch can fail because the record is new. In practice, we saw cases where touches were failing because the record had been destroyed. `persisted?` checks `new_record?` *and* `destroyed?`. It was confusing to get a message about a new record when in reality we were destroying records.
      
      I also included a helpful tip for users to consider using `persisted?`, `new_record?`, or `destroyed?` before touching.
      ac156060
    • V
      `travel/travel_to` travel time helpers, now raise on nested calls, · 919e7053
      Vipul A M 提交于
           as this can lead to confusing time stubbing.
      
           Instead of:
      
               travel_to 2.days.from_now do
                 # 2 days from today
                 travel_to 3.days.from_now do
                   # 5 days from today
                 end
               end
      
           preferred way to achieve above is:
      
               travel_to 2.days.from_now
               # 2 days from today
      
               travel_back
               travel_to 5.days.from_now
               # 5 days from today
      
      Closes #24690
      Fixes #24689
      919e7053
    • H
      Fix typo: accidently -> accidentally. · 5d9d3090
      Hendy Tanata 提交于
      5d9d3090
  8. 02 7月, 2016 3 次提交
  9. 01 7月, 2016 2 次提交
  10. 29 6月, 2016 3 次提交
  11. 27 6月, 2016 1 次提交
  12. 25 6月, 2016 3 次提交
  13. 24 6月, 2016 5 次提交
  14. 23 6月, 2016 1 次提交
  15. 22 6月, 2016 1 次提交
  16. 20 6月, 2016 1 次提交
  17. 17 6月, 2016 1 次提交
  18. 16 6月, 2016 1 次提交