I noticed this a while ago, so it might have been fixed when I removed the awful illegalstack plugin. I’ll have to do further testing but it’s something I thought it would be worth asking anyway since maybe somebody might have an easy fix to insure it never happens again.
Remove half of your non-essential (ie not things like PAPI or LuckPerm) plugins and see if the problem is fixed. If it still persists, the cause is in the half still installed. Continue to halve the remaining plugins until you've narrowed it down to a single plugin. Congratulations, you found the culprit.