Tag self-repair