Added functionality for the clear flag and cleaned up info logging.