Bug fixes & debug detection