mirror of
https://github.com/github/codeql-action.git
synced 2025-12-31 11:40:24 +08:00
Merge main into update-actions-github.
This commit is contained in:
@@ -875,28 +875,28 @@ async function loadConfig(
|
||||
if (!(parsedYAML[PATHS_IGNORE_PROPERTY] instanceof Array)) {
|
||||
throw new Error(getPathsIgnoreInvalid(configFile));
|
||||
}
|
||||
parsedYAML[PATHS_IGNORE_PROPERTY]!.forEach((path) => {
|
||||
for (const path of parsedYAML[PATHS_IGNORE_PROPERTY]!) {
|
||||
if (typeof path !== "string" || path === "") {
|
||||
throw new Error(getPathsIgnoreInvalid(configFile));
|
||||
}
|
||||
pathsIgnore.push(
|
||||
validateAndSanitisePath(path, PATHS_IGNORE_PROPERTY, configFile, logger)
|
||||
);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
if (PATHS_PROPERTY in parsedYAML) {
|
||||
if (!(parsedYAML[PATHS_PROPERTY] instanceof Array)) {
|
||||
throw new Error(getPathsInvalid(configFile));
|
||||
}
|
||||
parsedYAML[PATHS_PROPERTY]!.forEach((path) => {
|
||||
for (const path of parsedYAML[PATHS_PROPERTY]!) {
|
||||
if (typeof path !== "string" || path === "") {
|
||||
throw new Error(getPathsInvalid(configFile));
|
||||
}
|
||||
paths.push(
|
||||
validateAndSanitisePath(path, PATHS_PROPERTY, configFile, logger)
|
||||
);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// The list of queries should not be empty for any language. If it is then
|
||||
|
||||
Reference in New Issue
Block a user