mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Moved BaseView.absolute_url() to Datasette
This commit is contained in:
parent
274ef43bb7
commit
13ee3c222f
3 changed files with 9 additions and 9 deletions
|
|
@ -207,12 +207,6 @@ class BaseView(RenderMixin):
|
|||
|
||||
return name, expected, correct_hash_provided, None
|
||||
|
||||
def absolute_url(self, request, path):
|
||||
url = urllib.parse.urljoin(request.url, path)
|
||||
if url.startswith("http://") and self.ds.config("force_https_urls"):
|
||||
url = "https://" + url[len("http://"):]
|
||||
return url
|
||||
|
||||
def get_templates(self, database, table=None):
|
||||
assert NotImplemented
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue