From 6f5753cfa3ca3ff3ef41d22b8c9b6dc8c05426bc Mon Sep 17 00:00:00 2001 From: Wolfgang Bumiller Date: Tue, 10 May 2022 14:40:34 +0200 Subject: [PATCH] api-types: allow empty namespace Signed-off-by: Wolfgang Bumiller Signed-off-by: Thomas Lamprecht --- pbs-api-types/src/lib.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pbs-api-types/src/lib.rs b/pbs-api-types/src/lib.rs index 192acc71..f604c892 100644 --- a/pbs-api-types/src/lib.rs +++ b/pbs-api-types/src/lib.rs @@ -30,7 +30,9 @@ macro_rules! BACKUP_TIME_RE { () => (r"[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9] #[macro_export] macro_rules! BACKUP_NS_RE { () => ( - concat!(r"(?:", PROXMOX_SAFE_ID_REGEX_STR!(), r"/){0,7}", PROXMOX_SAFE_ID_REGEX_STR!()) + concat!("(?:", + "(?:", PROXMOX_SAFE_ID_REGEX_STR!(), r"/){0,7}", PROXMOX_SAFE_ID_REGEX_STR!(), + ")?") ); }