Allow logger to be disabled by setting it to false