mirror of
https://github.com/we-promise/sure.git
synced 2026-04-19 12:04:08 +00:00
Fix auto sync trigger logic and add tests
This commit is contained in:
@@ -34,6 +34,10 @@ module Syncable
|
||||
latest_sync&.last_ran_at
|
||||
end
|
||||
|
||||
def last_sync_created_at
|
||||
latest_sync&.created_at
|
||||
end
|
||||
|
||||
private
|
||||
def latest_sync
|
||||
syncs.order(created_at: :desc).first
|
||||
|
||||
Reference in New Issue
Block a user