mirror of
https://github.com/penpot/penpot.git
synced 2025-01-09 00:10:11 -05:00
Merge remote-tracking branch 'origin/staging' into develop
This commit is contained in:
commit
90d947391a
4 changed files with 25 additions and 22 deletions
|
@ -88,6 +88,12 @@
|
|||
- Fix scroll on color picker modal [Taiga #8353](https://tree.taiga.io/project/penpot/issue/8353)
|
||||
- Fix components are not dragged from the group to the assets tab [Taiga #8273](https://tree.taiga.io/project/penpot/issue/8273)
|
||||
|
||||
## 2.1.5
|
||||
|
||||
### :bug: Bugs fixed
|
||||
|
||||
- Fix broken webhooks [Taiga #8370](https://tree.taiga.io/project/penpot/issue/8370)
|
||||
|
||||
## 2.1.4
|
||||
|
||||
### :bug: Bugs fixed
|
||||
|
|
|
@ -263,6 +263,8 @@
|
|||
(assoc ::wrk/dedupe dedupe?)
|
||||
(assoc ::wrk/label label)
|
||||
(assoc ::wrk/params (-> params
|
||||
(dissoc :source)
|
||||
(dissoc :context)
|
||||
(dissoc :ip-addr)
|
||||
(dissoc :type)))))))
|
||||
params))
|
||||
|
|
|
@ -66,21 +66,18 @@
|
|||
(defmethod ig/init-key ::process-event-handler
|
||||
[_ cfg]
|
||||
(fn [{:keys [props] :as task}]
|
||||
(let [event (:event props)]
|
||||
(l/dbg :hint "process webhook event" :name (:name event))
|
||||
|
||||
(when-let [items (lookup-webhooks cfg event)]
|
||||
(l/trc :hint "webhooks found for event" :total (count items))
|
||||
|
||||
(db/tx-run! cfg (fn [cfg]
|
||||
(doseq [item items]
|
||||
(wrk/submit! (-> cfg
|
||||
(assoc ::wrk/task :run-webhook)
|
||||
(assoc ::wrk/queue :webhooks)
|
||||
(assoc ::wrk/max-retries 3)
|
||||
(assoc ::wrk/params {:event event
|
||||
:config item}))))))))))
|
||||
(l/dbg :hint "process webhook event" :name (:name props))
|
||||
|
||||
(when-let [items (lookup-webhooks cfg props)]
|
||||
(l/trc :hint "webhooks found for event" :total (count items))
|
||||
(db/tx-run! cfg (fn [cfg]
|
||||
(doseq [item items]
|
||||
(wrk/submit! (-> cfg
|
||||
(assoc ::wrk/task :run-webhook)
|
||||
(assoc ::wrk/queue :webhooks)
|
||||
(assoc ::wrk/max-retries 3)
|
||||
(assoc ::wrk/params {:event props
|
||||
:config item})))))))))
|
||||
;; --- RUN
|
||||
|
||||
(declare interpret-exception)
|
||||
|
|
|
@ -21,10 +21,9 @@
|
|||
(with-mocks [submit-mock {:target 'app.worker/submit! :return nil}]
|
||||
(let [prof (th/create-profile* 1 {:is-active true})
|
||||
res (th/run-task! :process-webhook-event
|
||||
{:event
|
||||
{:type "command"
|
||||
:name "create-project"
|
||||
:props {:team-id (:default-team-id prof)}}})]
|
||||
{:type "command"
|
||||
:name "create-project"
|
||||
:props {:team-id (:default-team-id prof)}})]
|
||||
|
||||
(t/is (= 0 (:call-count @submit-mock)))
|
||||
(t/is (nil? res)))))
|
||||
|
@ -34,10 +33,9 @@
|
|||
(let [prof (th/create-profile* 1 {:is-active true})
|
||||
whk (th/create-webhook* {:team-id (:default-team-id prof)})
|
||||
res (th/run-task! :process-webhook-event
|
||||
{:event
|
||||
{:type "command"
|
||||
:name "create-project"
|
||||
:props {:team-id (:default-team-id prof)}}})]
|
||||
{:type "command"
|
||||
:name "create-project"
|
||||
:props {:team-id (:default-team-id prof)}})]
|
||||
|
||||
(t/is (= 1 (:call-count @submit-mock)))
|
||||
(t/is (nil? res)))))
|
||||
|
|
Loading…
Reference in a new issue