Skip to content

Commit 696ee34

Browse files
committed
fix: handle undefined packet from parsePacket in scheduled task test page
1 parent 7d7ebdd commit 696ee34

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

apps/webapp/app/presenters/v3/TestTaskPresenter.server.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -382,6 +382,9 @@ export class TestTaskPresenter {
382382

383383
async function getScheduleTaskRunPayload(payload: string, payloadType: string) {
384384
const packet = await parsePacket({ data: payload, dataType: payloadType });
385+
if (!packet) {
386+
return { success: false as const };
387+
}
385388
if (!packet.timezone) {
386389
packet.timezone = "UTC";
387390
}

0 commit comments

Comments
 (0)