I'd like ask if there's a way to validate a string as an url or email at the same time?
for example:
validates_format_of :string, :with => [url_regex, email_regex]
string = 'http://domain.com' => valid
string = '[email protected]' => valid
thanks in advance!