Fixed random typo and added debug feature