From 047542149810709c2a2c41224d7500575f81b2bd Mon Sep 17 00:00:00 2001 From: Christoph Heiss Date: Fri, 12 Jan 2024 17:15:58 +0100 Subject: [PATCH] auth-api: implement `Display` for `Realm{, Ref}` Signed-off-by: Christoph Heiss --- proxmox-auth-api/src/types.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/proxmox-auth-api/src/types.rs b/proxmox-auth-api/src/types.rs index e11d0b1a..c014a720 100644 --- a/proxmox-auth-api/src/types.rs +++ b/proxmox-auth-api/src/types.rs @@ -301,6 +301,18 @@ impl PartialEq for &RealmRef { } } +impl fmt::Display for Realm { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + fmt::Display::fmt(&self.0, f) + } +} + +impl fmt::Display for RealmRef { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + fmt::Display::fmt(&self.0, f) + } +} + #[api( type: String, format: &PROXMOX_TOKEN_NAME_FORMAT,