diff --git a/.travis.yml b/.travis.yml index 95e2b02b1..da3c29b57 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,11 +6,10 @@ rvm: before_script: - "sass --update public/stylesheets/sass/:public/stylesheets/" - "cp config/database.yml.example config/database.yml" - - "rake db:drop" - "rake db:create" - "rake db:schema:load" - "rspec spec --tag fixture" - + - 'rails runner "puts ActiveRecord::Base.connection.collation"' script: "bundle exec rake travis" env: "TRAVIS=true" notifications: diff --git a/lib/pubsubhubbub.rb b/lib/pubsubhubbub.rb index b24b7f798..6de442a8e 100644 --- a/lib/pubsubhubbub.rb +++ b/lib/pubsubhubbub.rb @@ -12,7 +12,11 @@ class Pubsubhubbub end def publish(feed) - response = RestClient.post(@hub, :headers => @headers, 'hub.url' => feed, 'hub.mode' => 'publish') - response + begin + response = RestClient.post(@hub, :headers => @headers, 'hub.url' => feed, 'hub.mode' => 'publish') + return response + rescue RestClient::BadRequest=> e + Rails.logger.warn "Public URL for your users are incorrect. this is ok if you are in development and localhost is your pod_url#{e.inspect}" + end end end