lib/dynamoid/document.rb in dynamoid-0.0.3 vs lib/dynamoid/document.rb in dynamoid-0.0.4
- old
+ new
@@ -6,9 +6,11 @@
module Document
extend ActiveSupport::Concern
include Dynamoid::Components
attr_accessor :new_record
+ alias :persisted? :new_record
+ alias :new_record? :new_record
def initialize(attrs = {})
@new_record = true
@attributes ||= {}
self.class.attributes.each {|att| write_attribute(att, attrs[att])}
\ No newline at end of file