reworked logger to work properly and fixed some spelling errors