app/models/maestrano/connector/rails/concerns/synchronization.rb in maestrano-connector-rails-2.2.1 vs app/models/maestrano/connector/rails/concerns/synchronization.rb in maestrano-connector-rails-2.3.0
- old
+ new
@@ -34,18 +34,18 @@
def success?
status == SUCCESS_STATUS
end
def mark_as_success
- update_attributes(status: SUCCESS_STATUS)
+ update(status: SUCCESS_STATUS)
end
def mark_as_error(msg)
- update_attributes(status: ERROR_STATUS, message: msg)
+ update(status: ERROR_STATUS, message: msg)
end
def mark_as_partial
- update_attributes(partial: true)
+ update(partial: true)
end
def clean_synchronizations
count = organization.synchronizations.count
organization.synchronizations.order('id ASC').limit(count - 100).destroy_all if count > 100