new_tag -> new_tag_lower to fix UnboundLocalError