From 8952fc015fae476a20051c01cf4217d82d30c83d Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Thu, 5 Feb 2015 20:29:41 -0800 Subject: Apply default scope to labels and remove one for notes --- app/finders/notes_finder.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'app/finders') diff --git a/app/finders/notes_finder.rb b/app/finders/notes_finder.rb index 6fe15b41060..e2bd0a2560e 100644 --- a/app/finders/notes_finder.rb +++ b/app/finders/notes_finder.rb @@ -22,6 +22,7 @@ class NotesFinder end # Use overlapping intervals to avoid worrying about race conditions - notes.where('updated_at > ?', last_fetched_at - FETCH_OVERLAP) + notes.where('updated_at > ?', last_fetched_at - FETCH_OVERLAP). + order(created_at: :asc, id: :asc) end end -- cgit v1.2.1