1
3
mirror of https://github.com/charliermarsh/ruff synced 2025-10-05 15:42:51 +02:00

[ty] Fix playground crashes when accessing vendored files with leading slashes (#20661)

This commit is contained in:
Dan Parizher
2025-10-04 07:40:37 -04:00
committed by GitHub
parent 2ce3aba458
commit 2d44ad2f8f

View File

@@ -100,6 +100,10 @@ export default function Playground() {
setError("File names cannot start with '/'.");
return;
}
if (newName.startsWith("vendored:")) {
setError("File names cannot start with 'vendored:'.");
return;
}
const handle = files.handles[file];
let newHandle: FileHandle | null = null;