fix(workspace): resolve symlinks in workspace path before checking

pull/2573/head
Reinier van der Leer 2023-04-19 20:58:14 +02:00
parent a2723f16f2
commit 37ff26ec2c
No known key found for this signature in database
GPG Key ID: 64035FE419545762
1 changed files with 1 additions and 0 deletions

View File

@ -37,6 +37,7 @@ def safe_path_join(base: Path, *paths: str | Path) -> Path:
Returns:
Path: The joined path
"""
base = base.resolve()
joined_path = base.joinpath(*paths).resolve()
if CFG.restrict_to_workspace and not joined_path.is_relative_to(base):