Fix lint errors

This commit is contained in:
Loris Bettazza 2022-10-12 00:17:48 +02:00
parent 3901af1c18
commit 352c083e83
3 changed files with 5 additions and 5 deletions

View file

@ -2,7 +2,7 @@ import convict from "convict";
import { existsSync } from "fs";
// Define a schema
export let config = convict({
export const config = convict({
allowedFiletypes: {
doc: "Filetypes that are synchronized to the game.",
format: "Array",

View file

@ -37,7 +37,7 @@ describe("messageGenerators", () => {
const msg = fileRemovalEventToMsg({ path: "sub/test.js" });
const result = (msg?.params as FileData).filename;
if (result && result.hasOwnProperty("filename")) expect(result).to.eq("/sub/test.js");
if (result && Object.prototype.hasOwnProperty.call(result, "filename")) expect(result).to.eq("/sub/test.js");
});
});
@ -46,7 +46,7 @@ describe("messageGenerators", () => {
const msg = fileRemovalEventToMsg({ path: "test.js" });
const result = (msg?.params as FileData).filename;
if (result && result.hasOwnProperty("filename")) expect(result).to.eq("test.js");
if (result && Object.prototype.hasOwnProperty.call(result, "filename")) expect(result).to.eq("test.js");
});
});
@ -55,7 +55,7 @@ describe("messageGenerators", () => {
const msg = fileRemovalEventToMsg({ path: "/sub/test.js" });
const result = (msg?.params as FileData).filename;
if (result && result.hasOwnProperty("filename")) expect(result).to.eq("/sub/test.js");
if (result && Object.prototype.hasOwnProperty.call(result, "filename")) expect(result).to.eq("/sub/test.js");
});
});
});

View file

@ -1,5 +1,5 @@
import chai from "chai";
import { createSandbox, stub } from "sinon";
import { createSandbox } from "sinon";
import sinonChai from "sinon-chai";
export async function mochaGlobalSetup() {