New version with logger