FIX: If the host can't be extracted don't raise an error

This commit is contained in:
Robin Ward 2017-05-04 13:26:37 -04:00
parent 1768c45a33
commit 55ca5df96b

View File

@ -1,6 +1,8 @@
class IncomingDomain < ActiveRecord::Base
def self.add!(uri)
name = uri.host
return unless name.present?
https = uri.scheme == "https"
port = uri.port