Added logging.