Skip to content
Snippets Groups Projects
Commit 98daf6d3 authored by anhofmann's avatar anhofmann Committed by Charlie Smurthwaite
Browse files

Add possibility to use other ports than 80/443 in webhooks (#234)

* Added possibility to use other ports than 80/443

* simplify regex to allow colon anywhere
parent 5634640f
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -28,7 +28,7 @@ class Webhook < ApplicationRecord
has_many :webhook_requests
 
validates :name, :presence => true
validates :url, :presence => true, :format => {:with => /\Ahttps?\:\/\/[a-z0-9\-\.\_\?\&\/\+]+\z/i, :allow_blank => true}
validates :url, :presence => true, :format => {:with => /\Ahttps?\:\/\/[a-z0-9\-\.\_\?\&\/\+:]+\z/i, :allow_blank => true}
 
scope :enabled, -> { where(:enabled => true) }
 
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment