fix for public posts in development mode, in single process mode, when your pod_url is still set to localhost

This commit is contained in:
Maxwell Salzberg 2011-07-04 12:20:02 -07:00
parent 2e10643d00
commit f4f34e0faa

View file

@ -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