Fixed bug with logger