mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2025-10-14 12:52:04 +00:00
escape uri of path in get_file_path for http, https, ftp, ftps, dav, davs
This change aims to import a working path into Kodi if the network shared path is using http, https, ftp, ftps, dav or davs protocol.
This commit is contained in:
parent
e95e8d6a88
commit
62e8a46d95
1 changed files with 5 additions and 0 deletions
|
@ -3,6 +3,8 @@ from __future__ import division, absolute_import, print_function, unicode_litera
|
|||
|
||||
##################################################################################################
|
||||
|
||||
from requests.utils import requote_uri
|
||||
|
||||
from . import settings, LazyLogger
|
||||
|
||||
##################################################################################################
|
||||
|
@ -213,6 +215,9 @@ class API(object):
|
|||
protocol = path.split('://')[0]
|
||||
path = path.replace(protocol, protocol.lower())
|
||||
|
||||
if protocol.lower() in ("http", "https", "ftp", "ftps", "dav", "davs"):
|
||||
path = requote_uri(path)
|
||||
|
||||
return path
|
||||
|
||||
def get_user_artwork(self, user_id):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue