From 9d2f96b348c99fe376548de9a49b29e529f2ce2f Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20N=C3=A9grier?= Date: Tue, 28 Apr 2020 22:40:54 +0200 Subject: [PATCH] Manually fixing a weird lint bug in eslint --- back/package.json | 3 ++- back/src/Model/Group.ts | 8 ++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/back/package.json b/back/package.json index d4bf634..1ea43f3 100644 --- a/back/package.json +++ b/back/package.json @@ -8,7 +8,8 @@ "dev": "ts-node-dev --respawn --transpileOnly ./server.ts", "prod": "tsc && node ./dist/server.js", "test": "ts-node node_modules/jasmine/bin/jasmine --config=jasmine.json", - "lint": "node_modules/.bin/eslint src/ . --ext .ts" + "lint": "node_modules/.bin/eslint src/ . --ext .ts", + "fix": "node_modules/.bin/eslint src/ . --ext .ts" }, "repository": { "type": "git", diff --git a/back/src/Model/Group.ts b/back/src/Model/Group.ts index 38b9125..795c0e8 100644 --- a/back/src/Model/Group.ts +++ b/back/src/Model/Group.ts @@ -4,7 +4,7 @@ import { UserInterface } from "./UserInterface"; export class Group { static readonly MAX_PER_GROUP = 4; - + private users: UserInterface[]; private connectCallback: (user1: string, user2: string) => void; private disconnectCallback: (user1: string, user2: string) => void; @@ -14,7 +14,7 @@ export class Group { this.users = []; this.connectCallback = connectCallback; this.disconnectCallback = disconnectCallback; - + users.forEach((user: UserInterface) => { this.join(user); }); @@ -62,7 +62,7 @@ export class Group { removeFromGroup(users: UserInterface[]): void { - for(let i = 0; i < users.length; i++) { + for(let i = 0; i < users.length; i++){ let user = users[i]; const index = this.users.indexOf(user, 0); if (index > -1) { @@ -70,4 +70,4 @@ export class Group { } } } -} \ No newline at end of file +} -- 2.25.1