Refs #103 - Check for existence of logger before trying to log.
Refs #103 - Extract method.