Fix tag hierarchy