removal of hard codeing
This commit is contained in:
+2
-6
@@ -34,9 +34,7 @@ class PathMapper:
|
||||
relative_path = sonarr_path[len(sonarr_root):].lstrip('/')
|
||||
return str(Path(container_root) / relative_path) if relative_path else container_root
|
||||
|
||||
# Fallback: simple replacement for backward compatibility
|
||||
if sonarr_path.startswith("/mnt/unionfs/Media"):
|
||||
return sonarr_path.replace("/mnt/unionfs/Media", "/media")
|
||||
# No fallback - if path mapping fails, return original and let validation catch it
|
||||
return sonarr_path
|
||||
|
||||
def radarr_path_to_container_path(self, radarr_path: str) -> str:
|
||||
@@ -50,9 +48,7 @@ class PathMapper:
|
||||
relative_path = radarr_path[len(radarr_root):].lstrip('/')
|
||||
return str(Path(container_root) / relative_path) if relative_path else container_root
|
||||
|
||||
# Fallback: simple replacement for backward compatibility
|
||||
if radarr_path.startswith("/mnt/unionfs/Media"):
|
||||
return radarr_path.replace("/mnt/unionfs/Media", "/media")
|
||||
# No fallback - if path mapping fails, return original and let validation catch it
|
||||
return radarr_path
|
||||
|
||||
def container_path_to_host_path(self, container_path: str) -> str:
|
||||
|
||||
Reference in New Issue
Block a user