aboutsummaryrefslogtreecommitdiffstats
path: root/keystone-moon/keystone/common/wsgi.py
diff options
context:
space:
mode:
authorasteroide <thomas.duval@orange.com>2015-09-24 16:27:16 +0200
committerasteroide <thomas.duval@orange.com>2015-09-24 16:27:16 +0200
commit92d11d139e9f76d4fd76859aea78643fc32ef36b (patch)
treebd5a2e7b50853498074ab55bdaee4452c460010b /keystone-moon/keystone/common/wsgi.py
parent49325d99acfadaadfad99c596c4ada6b5ec849de (diff)
Update Keystone code from repository.
Change-Id: Ib3d0a06b10902fcc6d520f58e85aa617bc326d00
Diffstat (limited to 'keystone-moon/keystone/common/wsgi.py')
-rw-r--r--keystone-moon/keystone/common/wsgi.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/keystone-moon/keystone/common/wsgi.py b/keystone-moon/keystone/common/wsgi.py
index 0dee954b..8b99c87d 100644
--- a/keystone-moon/keystone/common/wsgi.py
+++ b/keystone-moon/keystone/common/wsgi.py
@@ -660,7 +660,8 @@ class RoutersBase(object):
get_action=None, head_action=None, get_head_action=None,
put_action=None, post_action=None, patch_action=None,
delete_action=None, get_post_action=None,
- path_vars=None, status=json_home.Status.STABLE):
+ path_vars=None, status=json_home.Status.STABLE,
+ new_path=None):
if get_head_action:
getattr(controller, get_head_action) # ensure the attribute exists
mapper.connect(path, controller=controller, action=get_head_action,
@@ -697,10 +698,10 @@ class RoutersBase(object):
resource_data = dict()
if path_vars:
- resource_data['href-template'] = path
+ resource_data['href-template'] = new_path or path
resource_data['href-vars'] = path_vars
else:
- resource_data['href'] = path
+ resource_data['href'] = new_path or path
json_home.Status.update_resource_data(resource_data, status)