Found a way to replicate the bug, now I can finally fix it.