Use default logger for setLogger and simplifications.

Feedback from code review.