Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Commits on Mar 31, 2015
  1. @yui-knk
  2. @claudiob

    Fix doc: set_callback also accepts an array of if:

    claudiob authored
    When Active Record calls `set_callback` inside `after_commit`,
    [these lines of code](
    pass an **array** of methods as the `:if` condition:
    options[:if] = Array(options[:if])
    options[:if] << "transaction_include_any_action?(#{fire_on})"
    That made me realize that anyone could pass an **array** of `:if` and `:unless`
    conditions to `set_callback`, since Active Support transforms these conditions
    into an array anyways in [these lines of code](
    @if      = Array(options[:if])
    @unless  = Array(options[:unless])
    Long story short, this commit updates the documentation of the `set_callback`
    method to explain that arrays are also accepted.
    It also replaces +false+ and +true+ with false and true, since any _falsey_ or
    _truthy_ value will work.
    [ci skip]
Commits on Mar 30, 2015
  1. @rafaelfranca
  2. @rafaelfranca

    Revert "Remove Array#inquiry"

    rafaelfranca authored
    This reverts commit 9420de5.
    Reason: Turns out we want to keep this method.
Commits on Mar 27, 2015
  1. @rafaelfranca

    Remove circular require

    rafaelfranca authored
  2. @rafaelfranca

    Remove Array#inquiry

    rafaelfranca authored
    We are promoting too much a feature that will not be widler used.
    So for now lets keep just the ArrayInquirer constructor.
  3. @rafaelfranca

    Merge pull request #18939 from georgeclaghorn/variant-inquiry

    rafaelfranca authored
    Provide friendlier access to request variants
  4. @amatsuda
Commits on Mar 26, 2015
  1. @vijaydev

    Merge branch 'master' of

    vijaydev authored
Commits on Mar 24, 2015
  1. @georgeclaghorn

    Add ActiveSupport::ArrayInquirer and Array#inquiry

    georgeclaghorn authored georgeclaghorn committed
    Wrapping an array in an `ArrayInquirer` gives a friendlier way to check its
    string-like contents. For example, `request.variant` returns an `ArrayInquirer`
    object. To check a request's variants, you can call:
        request.variant.any?(:phone, :tablet)
    ...instead of:
        request.variant.any? { |v|[:phone, :tablet]) }
    `Array#inquiry` is a shortcut for wrapping the receiving array in an
        pets = [:cat, :dog]    # => true
        pets.ferret? # => false
        pets.any?(:cat, :ferret} # => true
  2. @swalkinshaw

    Update ActiveSupport::Subscriber docs

    swalkinshaw authored
    For consistency purposes with the changes done in #12285
  3. @tgxworld
  4. @rafaelfranca

    Merge pull request #19485 from tgxworld/small_doc_fix

    rafaelfranca authored
    Small doc fix. [CI SKIP]
  5. @tgxworld

    Small doc fix. [CI SKIP]

    tgxworld authored
Commits on Mar 23, 2015
  1. @davidcornu
  2. @tgxworld
  3. @nerdinand
  4. @nerdinand
Commits on Mar 22, 2015
  1. @kirs
  2. @tgxworld

    Revert "Reduce allocations when running AR callbacks."

    tgxworld authored
    This reverts commit 796cab4.
Commits on Mar 20, 2015
  1. @rafaelfranca
  2. @rafaelfranca

    Merge pull request #19413 from kirs/replace-alias_method_chain

    rafaelfranca authored
    Replace occurences of alias_method_chain with their Module#prepend counterpart
  3. @kirs

    Use Module#prepend instead of alias_method_chain

    kirs authored
    Thanks @fbernier for suggestion! <3
    At this moment we can use Module#prepend in all all cases
    except of Range because of the bug [1] in MRI 2.2
  4. @amatsuda
Commits on Mar 17, 2015
  1. @rafaelfranca

    Merge pull request #19296 from Wildebeest/fix-race-ttl

    rafaelfranca authored
    Skip the `:race_condition_ttl` branch if the option is 0 or nil.
Commits on Mar 12, 2015
  1. @yui-knk
  2. @y-yagi
Commits on Mar 11, 2015
  1. @Wildebeest

    Skip the `:race_condition_ttl` branch if the option is 0 or nil. This…

    Wildebeest authored
    … fixes an issue with the redis cache, where this code will sometimes throw an error out of SETEX when passing 0 as the `expires_at`.
Commits on Mar 9, 2015
  1. @pixeltrix

    Revert "Take DST into account when locating TimeZone from Numeric."

    pixeltrix authored
    Reverting this as it's not the implementation that we would like it to be.
    This is being used inside of ActiveSUpport::TimeZone[] and it's unaware
    of the context in which to find the timezone period so the timezone found
    changes depending on whether DST is in effect for the current period.
    This means that `'2001-01-01'.in_time_zone(-9)` changes from winter/summer
    even though it's the same date that we're trying to convert.
    Since finding timezones by numeric offsets is a bit hit and miss we should
    introduce a new API for finding them which supplies the date context in
    which we want to search and we should probably also deprecate the finding
    of timezones via the [] method, though this needs further discussion.
    This reverts commit 2cc2fa3.
  2. @splattael

    Target Ruby 2.2.1 in gemspecs

    splattael authored
    This is a follow-up to #19257
Commits on Mar 7, 2015
  1. @wazery

    Doc fixes [ci skip]

    wazery authored
  2. @wazery

    Doc fix [ci skip]

    wazery authored
Commits on Mar 6, 2015
  1. @matthewd

    Merge pull request #19221 from matthewd/random-tests

    matthewd authored
    Run all our tests in random order
  2. @robin850

    Remove a duplicated changelog entry [ci skip]

    robin850 authored
    This entry now lives in the Action View's changelog ; refs 8a3bd08.
  3. @senny
Something went wrong with that request. Please try again.