summaryrefslogtreecommitdiff
path: root/app/models/ci/web_hook.rb
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-12-08 15:22:04 +0100
committerDouwe Maan <douwe@gitlab.com>2015-12-08 15:22:04 +0100
commit15925290eec4f5616e12ef3169794f85150e3270 (patch)
treeb1adb5784f74a05491a38b8656e179f451b79e5e /app/models/ci/web_hook.rb
parent0c3f70acf4838194f517c02874b8423303c21b48 (diff)
parent51ed5225adf4aac3ccbf715f8647258dac784abb (diff)
downloadgitlab-ce-15925290eec4f5616e12ef3169794f85150e3270.tar.gz
Merge branch 'master' into ui/dashboard-new-issueui/dashboard-new-issue
Diffstat (limited to 'app/models/ci/web_hook.rb')
-rw-r--r--app/models/ci/web_hook.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/app/models/ci/web_hook.rb b/app/models/ci/web_hook.rb
index 7ca16a1bde8..0dc15eb6683 100644
--- a/app/models/ci/web_hook.rb
+++ b/app/models/ci/web_hook.rb
@@ -20,8 +20,7 @@ module Ci
# HTTParty timeout
default_timeout 10
- validates :url, presence: true,
- format: { with: URI::regexp(%w(http https)), message: "should be a valid url" }
+ validates :url, presence: true, url: true
def execute(data)
parsed_url = URI.parse(url)