summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--openstack_dashboard/api/cinder.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/openstack_dashboard/api/cinder.py b/openstack_dashboard/api/cinder.py
index cfd17386d..43864627d 100644
--- a/openstack_dashboard/api/cinder.py
+++ b/openstack_dashboard/api/cinder.py
@@ -616,9 +616,12 @@ def volume_backup_create(request,
container_name,
name,
description):
+ # need to ensure the container name is not an empty
+ # string, but pass None to get the container name
+ # generated correctly
backup = cinderclient(request).backups.create(
volume_id,
- container=container_name,
+ container=container_name if container_name else None,
name=name,
description=description)
return VolumeBackup(backup)