added debug module and removed console-logs