Sha256: 1a67608f63ccf04652089cd8c2f0a529849f9e4191fe42545c37d950cb13d155

Contents?: true

Size: 231 Bytes

Versions: 1

Compression:

Stored size: 231 Bytes

Contents

module ActiveRecord
  module AttributeMethods
    def has_attribute?(attr_name)
      # CPK
      # @attributes.key?(attr_name.to_s)
      Array(attr_name).all? {|single_attr| @attributes.key?(single_attr.to_s) }
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
composite_primary_keys-12.0.10 lib/composite_primary_keys/attribute_methods.rb