Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Small fixes in server

  • Loading branch information...
commit bcd909767357c1632e0ee8162139522f13b5db00 1 parent bb49f90
Bartosz Pranczke authored

Showing 1 changed file with 4 additions and 3 deletions. Show diff stats Hide diff stats

  1. +4 3 server/server.rb
7 server/server.rb
@@ -24,7 +24,7 @@ class Domain
24 24 Email.auto_migrate! unless Email.storage_exists?
25 25 Domain.auto_migrate! unless Domain.storage_exists?
26 26 # First domain to crawl
27   - Domain.create(url: "http://192.168.56.1:4567", visited: false, visited_at: Time.now-6000)
  27 + Domain.create(url: "http://192.168.56.1:4567")
28 28 end
29 29
30 30 get '/' do
@@ -38,7 +38,7 @@ class Domain
38 38
39 39 content_type :json
40 40 if domain = Domain.first(visited_at: nil)
41   - else # If nothing lefts return the oldest domain to crawl
  41 + else # If nothing left return the oldest domain to crawl
42 42 domain = Domain.first(visited_at: Domain.min(:visited_at))
43 43 end
44 44 domain.update(visited_at: Time.now) unless domain.nil?
@@ -82,4 +82,5 @@ class Domain
82 82 @@ items
83 83 %h2== #{@items.count} gathered.
84 84 - @items.each do |i|
85   - %p= i['url']
  85 + %ul
  86 + %li= i['url']

0 comments on commit bcd9097

Please sign in to comment.
Something went wrong with that request. Please try again.