documentation: Call TemplateView.get correctly.

The calling arguments here are completely wrong. The first argument
should be `request`, and `self` should never get passed to `.get`.

Because `TemplateView` happened to not use `request`, and we happened
to pass `article` as a keyword argument, this error slipped through.

Signed-off-by: Zixuan James Li <p359101898@gmail.com>
This commit is contained in:
Zixuan James Li
2022-07-19 11:46:50 -04:00
committed by Tim Abbott
parent eb2ee5605c
commit 5a15fd1dd2

View File

@@ -232,7 +232,7 @@ class MarkdownDirectoryView(ApiURLView):
documentation_article = self.get_path(article)
http_status = documentation_article.article_http_status
result = super().get(self, article=article)
result = super().get(request, article=article)
if http_status != 200:
result.status_code = http_status
return result