Skip to content

Commit ad8d634

Browse files
committed
feat(operator): Also trim whitespace in image_name
1 parent 84b128e commit ad8d634

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

crates/stackable-operator/src/commons/product_image_selection.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,8 +199,9 @@ impl ProductImage {
199199
}
200200
};
201201

202-
// Trim the start to ensure no double slashes are produced below
203-
let image_name = image_name.trim_start_matches('/');
202+
// Trim leading ans trailing whitespace and also trim the start to ensure no double
203+
// slashes are produced below
204+
let image_name = image_name.trim().trim_start_matches('/');
204205
let app_version = format!("{product_version}-stackable{stackable_version}");
205206
let app_version_label_value = Self::prepare_app_version_label_value(&app_version)?;
206207
let image = format!("{image_repository}/{image_name}:{app_version}");

0 commit comments

Comments
 (0)