Browse Source

Break as soon as there's a thread with no new posts

master
Dylan Baker 4 years ago
parent
commit
ad763890e5
1 changed files with 1 additions and 2 deletions
  1. 1
    2
      db/scrape.rb

+ 1
- 2
db/scrape.rb View File

112
 
112
 
113
       last_post = posts.last
113
       last_post = posts.last
114
       unless db.from(:posts).first(remote_id: last_post[:remote_id]).nil?
114
       unless db.from(:posts).first(remote_id: last_post[:remote_id]).nil?
115
-        puts '  Up to date, skipping'
116
-        next
115
+        break
117
       end
116
       end
118
 
117
 
119
       posts_count = posts.size
118
       posts_count = posts.size

Loading…
Cancel
Save