mirror of
https://github.com/lucaspalomodevelop/indico-plugins.git
synced 2026-03-12 23:27:22 +00:00
URSH: Fix error when normalizing URL
This commit is contained in:
parent
bd7a1b0dcc
commit
6c3c1a2f1d
@ -6,7 +6,7 @@
|
||||
# see the LICENSE file for more details.
|
||||
|
||||
import posixpath
|
||||
from urllib.parse import urlsplit
|
||||
from urllib.parse import urlsplit, urlunsplit
|
||||
|
||||
from flask import jsonify, request, session
|
||||
from flask_pluginengine import render_plugin_template
|
||||
@ -74,7 +74,7 @@ class RHCustomShortURLPage(RHManageEventBase):
|
||||
from indico_ursh.plugin import UrshPlugin
|
||||
super()._process_args()
|
||||
api_host = urlsplit(UrshPlugin.settings.get('api_host'))
|
||||
self.ursh_host = strip_end(api_host.to_url(), api_host.path[1:]).rstrip('/') + '/'
|
||||
self.ursh_host = strip_end(urlunsplit(api_host), api_host.path[1:]).rstrip('/') + '/'
|
||||
|
||||
def _process_GET(self):
|
||||
original_url = self._make_absolute_url(request.args['original_url'])
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user