Remove the LGTM configuration and inline disable comments (issue 13829)
Given that the GitHub Advanced Security workflow now covers everything that LGTM does, but generally faster and with better GitHub-integration, there's no longer much point in also running LGTM separately. As a follow-up to this patch, we should also disable/remove the LGTM-integration from the PDF.js repository.
This commit is contained in:
parent
01fd0f59b7
commit
8fef8630fe
9
lgtm.yml
9
lgtm.yml
@ -1,9 +0,0 @@
|
|||||||
path_classifiers:
|
|
||||||
test:
|
|
||||||
- exclude: test
|
|
||||||
- test/resources
|
|
||||||
|
|
||||||
queries:
|
|
||||||
# Already handled by the "no-unused-vars" ESLint rule.
|
|
||||||
- exclude: js/unused-local-variable
|
|
||||||
- exclude: js/useless-assignment-to-local
|
|
@ -66,7 +66,7 @@ class FileSpec {
|
|||||||
get filename() {
|
get filename() {
|
||||||
if (!this._filename && this.root) {
|
if (!this._filename && this.root) {
|
||||||
const filename = pickPlatformItem(this.root) || "unnamed";
|
const filename = pickPlatformItem(this.root) || "unnamed";
|
||||||
this._filename = stringToPDFString(filename) // lgtm [js/double-escaping]
|
this._filename = stringToPDFString(filename)
|
||||||
.replace(/\\\\/g, "\\")
|
.replace(/\\\\/g, "\\")
|
||||||
.replace(/\\\//g, "/")
|
.replace(/\\\//g, "/")
|
||||||
.replace(/\\/g, "/");
|
.replace(/\\/g, "/");
|
||||||
|
@ -22,7 +22,7 @@ describe("Interaction", () => {
|
|||||||
}
|
}
|
||||||
await action();
|
await action();
|
||||||
await page.waitForFunction(
|
await page.waitForFunction(
|
||||||
`document.querySelector("${selector.replace("\\", "\\\\")}").value !== ""` // lgtm [js/incomplete-sanitization]
|
`document.querySelector("${selector.replace("\\", "\\\\")}").value !== ""`
|
||||||
);
|
);
|
||||||
return page.$eval(selector, el => el.value);
|
return page.$eval(selector, el => el.value);
|
||||||
}
|
}
|
||||||
|
@ -153,7 +153,7 @@ WebServer.prototype = {
|
|||||||
fileSize = stats.size;
|
fileSize = stats.size;
|
||||||
var isDir = stats.isDirectory();
|
var isDir = stats.isDirectory();
|
||||||
if (isDir && !/\/$/.test(pathPart)) {
|
if (isDir && !/\/$/.test(pathPart)) {
|
||||||
res.setHeader("Location", pathPart + "/" + urlParts[2]); // lgtm [js/server-side-unvalidated-url-redirection]
|
res.setHeader("Location", pathPart + "/" + urlParts[2]);
|
||||||
res.writeHead(301);
|
res.writeHead(301);
|
||||||
res.end("Redirected", "utf8");
|
res.end("Redirected", "utf8");
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user