Fix add_rule