Sha256: 399627e69a0bb4b30594c865b6e5bb393c547dd9b1f3066b6fe0b8dcc91ec1ec
Contents?: true
Size: 497 Bytes
Versions: 1
Compression:
Stored size: 497 Bytes
Contents
# frozen_string_literal: true module Dynamoid module Persistence # @private module UpdateValidations def self.validate_attributes_exist(model_class, attributes) model_attributes = model_class.attributes.keys attributes.each_key do |attr_name| unless model_attributes.include?(attr_name) raise Dynamoid::Errors::UnknownAttribute, "Attribute #{attr_name} does not exist in #{model_class}" end end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
dynamoid-3.10.0 | lib/dynamoid/persistence/update_validations.rb |