Links in the REST API should be absolute. The next patch will
centralize this in the Result object, in the meanwhile fix the
git plugin.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
mods/git.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/mods/git.py b/mods/git.py
index 4fd7dbe..69b5da8 100644
--- a/mods/git.py
+++ b/mods/git.py
@@ -123,8 +123,8 @@ class GitModule(PatchewModule):
git_tag = message.get_property("git.tag")
data = {'repo': git_repo, 'tag': 'refs/tags/' + git_tag}
result = {'status': 'success', 'data': data}
- result['log_url'] = reverse("git-log",
- kwargs={'series': message.message_id})
+ log_url = reverse("git-log", kwargs={'series': message.message_id})
+ result['log_url'] = request.build_absolute_uri(log_url)
else:
result = {'status': 'pending'}
results['git'] = result
--
2.16.2
_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://www.redhat.com/mailman/listinfo/patchew-devel