mirror of
https://github.com/github/awesome-copilot.git
synced 2026-06-20 14:37:49 +00:00
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -148,7 +148,7 @@ function normalizeRelativePath(value) {
|
|||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cleaned.includes("..")) {
|
if (/(^|\/)\.\.(\/|$)/.test(cleaned)) {
|
||||||
throw new Error(`Unsafe relative path in changed files list: ${value}`);
|
throw new Error(`Unsafe relative path in changed files list: ${value}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user