~bigbes/core-go: 2624a28a

webhooks: do not crash when expire is NULL

This is currently not possible to create a webhook without an expiry
date. But the SQL database schema does not forbid it. If in the future
we would like to allow webhooks to be created without an expiry date, we
shouldn't crash when fetching them.

Check for the validity of the Expiry field before checking its value. If
it is nil, assume that the webhooks has no expiry date.

Signed-off-by: Robin Jarry <robin@jarry.cc>

Robin Jarry <robin@jarry.cc> — 2024-11-25 14:24:01 UTC

Commit 2624a28a52b29713f7ac13b95e0d43f969a1d47cview raw patch

Parent(s): e559510f

1 changed file(s)

FileStatus+
webhooks/queue.go M +1 -1