mirror of
https://github.com/plankanban/planka.git
synced 2025-12-20 01:14:12 +03:00
fix: Move webhooks declaration to correct position
This commit is contained in:
@@ -27,6 +27,8 @@ module.exports = {
|
||||
record: inputs.project,
|
||||
});
|
||||
|
||||
const webhooks = await Webhook.qm.getAll();
|
||||
|
||||
if (inputs.project.backgroundType === Project.BackgroundTypes.IMAGE) {
|
||||
if (inputs.record.id === inputs.project.backgroundImageId) {
|
||||
await sails.helpers.projects.updateOne.with({
|
||||
@@ -59,8 +61,6 @@ module.exports = {
|
||||
);
|
||||
});
|
||||
|
||||
const webhooks = await Webhook.qm.getAll();
|
||||
|
||||
sails.helpers.utils.sendWebhooks.with({
|
||||
webhooks,
|
||||
event: Webhook.Events.BACKGROUND_IMAGE_DELETE,
|
||||
|
||||
Reference in New Issue
Block a user