Only add logging handler if nothing is configured