From: Fam Zheng <famz@redhat.com>
This will be useful soon to extract information from the request useful
to generate mod content.
Signed-off-by: Fam Zheng <famz@redhat.com>
---
mods/footer.py | 2 +-
www/views.py | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/mods/footer.py b/mods/footer.py
index a947253..048bbcb 100644
--- a/mods/footer.py
+++ b/mods/footer.py
@@ -30,6 +30,6 @@ The config is the raw HTML code to inject.
name = "footer"
default_config = _default_config
- def render_page_hook(self, context_data):
+ def render_page_hook(self, request, context_data):
context_data.setdefault("footer", "")
context_data["footer"] += self.get_config_raw()
diff --git a/www/views.py b/www/views.py
index 2aae127..0dc146e 100644
--- a/www/views.py
+++ b/www/views.py
@@ -37,7 +37,7 @@ def try_get_git_head():
def render_page(request, template_name, **data):
data["patchew_version"] = settings.VERSION + try_get_git_head()
- dispatch_module_hook("render_page_hook", context_data=data)
+ dispatch_module_hook("render_page_hook", request=request, context_data=data)
return render(request, template_name, context=data)
--
2.17.2
_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://www.redhat.com/mailman/listinfo/patchew-devel