Deleted documents reappearing

This occurred again today and I was able to get the logs from the sync gateway:

2023-08-07T12:51:18.728Z [WRN] Null doc body/rawBody docId/ from  -- db.(*Document).BodyBytes() at document.go:306
2023-08-07T12:51:18.728Z [WRN] Null doc body/rawBody docId/ from  -- db.(*Document).Body() at document.go:245
2023-08-07T12:51:18.731Z [WRN] Null doc body/rawBody docId/ from  -- db.(*Document).Body() at document.go:245
2023-08-07T12:51:18.732Z [INF] CRUD: 	Doc "docId" / "2-961e0ef91b16bacaa63f6817100d6237" in channels "{server}"

I can see that it happens at this line in the code:

But I’m unsure where to follow the code from there…

The same error message is also referenced here:

But I’m not sure if this is related. Can anyone maybe advise how I can debug further?