Keep the written image name in update suggestions

docker.io/calico/node was suggested as calico/node, which reads as a
different image and would rewrite the workload's reference.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Dennis Nemec
2026-09-03 20:33:36 +02:00
parent 44b7a56573
commit 1cb634afca

View File

@ -7,6 +7,8 @@ pub struct ImageRef {
pub registry: String, pub registry: String,
pub repository: String, pub repository: String,
pub tag: String, pub tag: String,
/// The name exactly as it was written, so a suggestion keeps the original spelling.
pub name: String,
} }
impl ImageRef { impl ImageRef {
@ -34,6 +36,7 @@ impl ImageRef {
registry, registry,
repository, repository,
tag, tag,
name: head.to_string(),
}) })
} }