Sha256: 9a7cd9cba12687d6297d8db625911ebae316986116ad5466c2ee4aec8ac2d582

Contents?: true

Size: 702 Bytes

Versions: 30

Compression:

Stored size: 702 Bytes

Contents

ActiveSupport::Deprecation.warn("The Chargify gem is patching your ActiveModel because it is less than version 3.0.20! (https://github.com/chargify/chargify_api_ares/blob/master/README.md)")

module ActiveModel
  module Serializers
    module Xml
      class Serializer
        class Attribute
          protected

          # Patch `compute_type` to avoid adding `type="yaml"` to
          # nil attributes in < 3.0.20 ActiveModel
          #
          # See https://github.com/rails/rails/pull/8853
          alias_method :compute_type_orig, :compute_type
          def compute_type
            return if value.nil?
            compute_type_orig
          end
        end
      end
    end
  end
end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
chargify_api_ares-1.4.15 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.14 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.13 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.11 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.10 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.7 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.6 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.5 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.4 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.3 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.2 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.1 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.4.0 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.3.5 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.3.4 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.3.3 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.3.2 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.3.1 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.3.0 lib/patches/activemodel_3_0_patch.rb
chargify_api_ares-1.2.1 lib/patches/activemodel_3_0_patch.rb