1
0
Fork 0
mirror of https://github.com/plankanban/planka.git synced 2025-07-18 20:59:44 +02:00

fix: Handle webhooks correctly during socket reconnection

This commit is contained in:
Maksim Eltyshev 2025-07-08 12:41:27 +02:00
parent 9d07178e57
commit b76ca9547f

View file

@ -30,9 +30,11 @@ export default class extends BaseModel {
case ActionTypes.SOCKET_RECONNECT_HANDLE: case ActionTypes.SOCKET_RECONNECT_HANDLE:
Webhook.all().delete(); Webhook.all().delete();
if (payload.webhooks) {
payload.webhooks.forEach((webhook) => { payload.webhooks.forEach((webhook) => {
Webhook.upsert(webhook); Webhook.upsert(webhook);
}); });
}
break; break;
case ActionTypes.CORE_INITIALIZE: case ActionTypes.CORE_INITIALIZE: