- commit
- f596e3b2b47fdefe6bef8f29849e24815505c13a
- parent
- 4865421db04eca17872cb5748dec7752c533f071
- Author
- Tobias Bengfort <tobias.bengfort@posteo.de>
- Date
- 2022-11-22 07:52
ignore URLs in relpath()
Diffstat
| M | cplay.py | 4 | +++- |
1 files changed, 3 insertions, 1 deletions
diff --git a/cplay.py b/cplay.py
@@ -100,7 +100,9 @@ def get_socket(path): 100 100 101 101 @functools.lru_cache() 102 102 def relpath(path):103 -1 if path.startswith(filelist.path):-1 103 if path.startswith('http'): -1 104 return path -1 105 elif path.startswith(filelist.path): 104 106 return path[len(filelist.path):].lstrip('/') 105 107 else: 106 108 return os.path.relpath(path)