From 85570639cbfed76cf5c9221b37d14e6d20ecbd37 Mon Sep 17 00:00:00 2001 From: alfonsomthd Date: Mon, 22 Oct 2018 19:38:38 +0200 Subject: [PATCH] mgr/dashboard: Add TSLint rule - TSlint no-unused-variable rule added. - Cleanup: unused imports and variables. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Alfonso Martínez --- .../ceph/block/rbd-snapshot-list/rbd-snapshot-list.component.ts | 1 - .../configuration-form/configuration-form.component.spec.ts | 2 -- src/pybind/mgr/dashboard/frontend/tslint.json | 1 + 3 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-snapshot-list/rbd-snapshot-list.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-snapshot-list/rbd-snapshot-list.component.ts index 0c44327bfb7fe..ccf2a7488717f 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-snapshot-list/rbd-snapshot-list.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-snapshot-list/rbd-snapshot-list.component.ts @@ -1,6 +1,5 @@ import { Component, Input, OnChanges, OnInit, TemplateRef, ViewChild } from '@angular/core'; -import * as _ from 'lodash'; import * as moment from 'moment'; import { BsModalRef, BsModalService } from 'ngx-bootstrap'; import { of } from 'rxjs'; diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/configuration/configuration-form/configuration-form.component.spec.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/configuration/configuration-form/configuration-form.component.spec.ts index cbc89885248a1..2d369db25b3b1 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/configuration/configuration-form/configuration-form.component.spec.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/configuration/configuration-form/configuration-form.component.spec.ts @@ -14,7 +14,6 @@ import { ConfigFormModel } from './configuration-form.model'; describe('ConfigurationFormComponent', () => { let component: ConfigurationFormComponent; let fixture: ComponentFixture; - let activatedRoute: ActivatedRoute; configureTestBed({ imports: [ @@ -35,7 +34,6 @@ describe('ConfigurationFormComponent', () => { beforeEach(() => { fixture = TestBed.createComponent(ConfigurationFormComponent); component = fixture.componentInstance; - activatedRoute = TestBed.get(ActivatedRoute); }); it('should create', () => { diff --git a/src/pybind/mgr/dashboard/frontend/tslint.json b/src/pybind/mgr/dashboard/frontend/tslint.json index 0f4de926631fc..ce258f6491398 100644 --- a/src/pybind/mgr/dashboard/frontend/tslint.json +++ b/src/pybind/mgr/dashboard/frontend/tslint.json @@ -41,6 +41,7 @@ "no-trailing-whitespace": true, "no-unnecessary-initializer": true, "no-unused-expression": true, + "no-unused-variable": true, "no-use-before-declare": true, "no-var-keyword": true, "object-literal-sort-keys": false,