Fix bug where tags shown first would cause selected_type inverted.