mirror of
https://github.com/kkapsner/CanvasBlocker
synced 2024-12-22 21:00:23 +01:00
eslint cleanup
This commit is contained in:
parent
627ee6d21e
commit
3dc39e11a5
@ -51,6 +51,7 @@
|
||||
"no-unused-vars": "off",
|
||||
"no-use-before-define": ["error", {"functions": false}],
|
||||
"no-useless-rename": "warn",
|
||||
"no-useless-return": "warn",
|
||||
"no-var": "error",
|
||||
"quotes": ["error", "double"],
|
||||
"require-atomic-updates": "off",
|
||||
|
@ -29,7 +29,6 @@ async function getMessagesInFile(path){
|
||||
return getMessagesInContent(content);
|
||||
}
|
||||
else {
|
||||
// eslint-disable-next-line no-console
|
||||
console.log("file does not exist:", path);
|
||||
return [];
|
||||
}
|
||||
|
@ -130,7 +130,6 @@
|
||||
function interceptWindow(window){
|
||||
let wrappedTry;
|
||||
try {
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
const href = window.location.href;
|
||||
wrappedTry = extension.getWrapped(window);
|
||||
}
|
||||
|
@ -218,7 +218,6 @@
|
||||
getChannelData: {
|
||||
object: ["AudioBuffer"],
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function getChannelData(channel){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
@ -236,7 +235,6 @@
|
||||
copyFromChannel: {
|
||||
object: ["AudioBuffer"],
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function copyFromChannel(destination, channelNumber, startInChannel){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
@ -255,7 +253,6 @@
|
||||
getFrequencyResponse: {
|
||||
object: ["BiquadFilterNode", "IIRFilterNode"],
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function getFrequencyResponse(frequencyArray, magResponseOutput, phaseResponseOutput){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
|
@ -302,7 +302,6 @@
|
||||
},
|
||||
object: "HTMLCanvasElement",
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function(context, contextAttributes){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {window, original} = check;
|
||||
@ -357,7 +356,6 @@
|
||||
},
|
||||
object: "HTMLCanvasElement",
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function toBlob(callback){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
@ -390,7 +388,6 @@
|
||||
},
|
||||
object: "HTMLCanvasElement",
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function mozGetAsFile(callback){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
@ -418,7 +415,6 @@
|
||||
},
|
||||
object: "CanvasRenderingContext2D",
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function getImageData(sx, sy, sw, sh){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
@ -517,7 +513,6 @@
|
||||
},
|
||||
object: "CanvasRenderingContext2D",
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function fillText(str, x, y){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
@ -554,7 +549,6 @@
|
||||
},
|
||||
object: "CanvasRenderingContext2D",
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
return function strokeText(str, x, y){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
@ -591,7 +585,7 @@
|
||||
},
|
||||
object: ["WebGLRenderingContext", "WebGL2RenderingContext"],
|
||||
fakeGenerator: function(checker){
|
||||
// eslint-disable-next-line max-params, no-unused-vars
|
||||
// eslint-disable-next-line max-params
|
||||
return function readPixels(x, y, width, height, format, type, pixels){
|
||||
return checkerWrapper(checker, this, arguments, function(args, check){
|
||||
const {prefs, notify, window, original} = check;
|
||||
|
@ -200,7 +200,7 @@
|
||||
return function getConstantPixelRng(length, window, ignoredColors){
|
||||
const rng = scope.nonPersistent.getValueRng(1024, window);
|
||||
|
||||
// eslint-disable-next-line max-params, no-unused-vars
|
||||
// eslint-disable-next-line max-params
|
||||
return function(r, g, b, a, i){
|
||||
const index = String.fromCharCode(r, g, b, a);
|
||||
if (ignoredColors[index]){
|
||||
|
Loading…
x
Reference in New Issue
Block a user