From f9742fabec9de628958c859a8c1146d07f6997a2 Mon Sep 17 00:00:00 2001 From: BroodjeAap Date: Fri, 6 Jan 2023 10:27:38 +0000 Subject: [PATCH] fixed prune delete when nothing to prune --- main.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/main.go b/main.go index d4a869e..3d9183a 100644 --- a/main.go +++ b/main.go @@ -279,7 +279,9 @@ func (web *Web) pruneDB() { IDs = append(IDs, b.ID) } } - web.db.Delete(&FilterOutput{}, IDs) + if len(IDs) > 0 { + web.db.Delete(&FilterOutput{}, IDs) + } } }