Fix crash in case webhook with nil url exists for a repo

This commit is contained in:
Teemu Patja 2017-03-06 15:11:54 +02:00
parent bb9ae35fd5
commit f2c74fe4e7
No known key found for this signature in database
GPG Key ID: F5B7035E6580FD4C

View File

@ -99,7 +99,7 @@
(let [hooks (repos/hooks owner repo (auth-params token))
url-base (:server-address env)]
(log/debug "url-base" url-base)
(filter (fn [{{url :url} :config}] (str/starts-with? url url-base))
(filter (fn [{{url :url} :config}] (and url (str/starts-with? url url-base)))
hooks)))