Fix bug with logger usage