app/models/mautic/contact.rb in mautic-2.2.2 vs app/models/mautic/contact.rb in mautic-2.3.1

- old
+ new

@@ -12,11 +12,15 @@ end def assign_attributes(source = nil) super self.attributes = { - tags: (source['tags'] || []).collect{|t| Mautic::Tag.new(@connection, t)} + tags: (source['tags'] || []).collect { |t| Mautic::Tag.new(@connection, t) }.sort_by(&:name) } if source + end + + def events + @proxy_events ||= Proxy.new(connection, "contacts/#{id}/events", klass: "Mautic::Event") end end end \ No newline at end of file