From ef72f513b17696ec4c749288144f551d9ef291bc Mon Sep 17 00:00:00 2001 From: Thomas Rittson <31796059+eliykat@users.noreply.github.com> Date: Mon, 10 Mar 2025 23:33:08 +1000 Subject: [PATCH] eslint: report unused disable directives (#13463) Remove any unused disable directives and FIXMEs in our code --- apps/browser/postcss.config.js | 2 +- .../src/auth/popup/settings/account-security.component.ts | 1 - .../background/overlay.background.deprecated.spec.ts | 1 - apps/browser/src/autofill/services/autofill.service.ts | 1 - apps/browser/src/background/idle.background.ts | 4 ---- .../task-scheduler/browser-task-scheduler.service.spec.ts | 4 +--- apps/browser/tailwind.config.js | 2 +- apps/cli/src/commands/get.command.ts | 2 +- apps/desktop/postcss.config.js | 2 +- apps/desktop/src/app/accounts/settings.component.ts | 1 - apps/desktop/src/app/app.component.ts | 4 ---- apps/desktop/src/auth/two-factor-v1.component.ts | 1 - apps/desktop/src/main/window.main.ts | 1 - apps/desktop/src/platform/services/electron-key.service.ts | 2 -- apps/desktop/src/vault/app/vault/vault-items.component.ts | 1 - apps/desktop/tailwind.config.js | 2 +- apps/web/postcss.config.js | 2 +- .../organizations/members/members.component.ts | 3 --- .../organizations/policies/policies.component.ts | 1 - .../organizations/settings/two-factor-setup.component.ts | 1 - apps/web/src/app/app.component.ts | 6 ------ apps/web/src/app/auth/login/login-v1.component.ts | 1 - .../settings/emergency-access/emergency-access.component.ts | 1 - .../takeover/emergency-access-takeover.component.ts | 2 -- .../view/emergency-access-view.component.ts | 1 - apps/web/src/app/auth/sso-v1.component.ts | 1 - apps/web/src/app/auth/two-factor-v1.component.ts | 1 - apps/web/src/app/auth/verify-email-token.component.ts | 1 - apps/web/src/app/auth/verify-recover-delete.component.ts | 1 - apps/web/src/app/billing/shared/payment-method.component.ts | 1 - apps/web/src/app/billing/shared/tax-info.component.ts | 3 +-- apps/web/src/app/core/core.module.ts | 1 - .../app/tools/reports/pages/breach-report.component.spec.ts | 1 - .../pages/exposed-passwords-report.component.spec.ts | 1 - .../pages/inactive-two-factor-report.component.spec.ts | 1 - .../organizations/exposed-passwords-report.component.ts | 2 -- .../organizations/inactive-two-factor-report.component.ts | 2 -- .../organizations/reused-passwords-report.component.ts | 2 -- .../organizations/unsecured-websites-report.component.ts | 2 -- .../pages/organizations/weak-passwords-report.component.ts | 2 -- .../reports/pages/reused-passwords-report.component.spec.ts | 1 - .../pages/unsecured-websites-report.component.spec.ts | 1 - .../reports/pages/weak-passwords-report.component.spec.ts | 1 - apps/web/src/app/tools/send/send-access/access.component.ts | 1 - .../domain-verification/domain-verification.component.ts | 1 - .../admin-console/organizations/manage/scim.component.ts | 1 - .../providers/clients/create-organization.component.ts | 1 - .../app/admin-console/providers/manage/events.component.ts | 1 - .../admin-console/providers/settings/account.component.ts | 1 - .../providers/verify-recover-delete-provider.component.ts | 1 - .../tools/access-intelligence/risk-insights.component.ts | 1 - eslint.config.mjs | 3 +++ .../auth/components/login-via-auth-request-v1.component.ts | 1 - .../src/auth/components/two-factor-v1.component.spec.ts | 1 - libs/angular/src/auth/components/two-factor-v1.component.ts | 1 - .../src/auth/components/user-verification.component.ts | 1 - .../two-factor-auth/two-factor-auth.component.spec.ts | 1 - .../user-verification-form-input.component.ts | 1 - .../src/auth/models/request/identity-token/token.request.ts | 1 - libs/common/src/state-migrations/migration-helper.spec.ts | 1 - libs/components/src/test.setup.ts | 1 - .../src/importers/spec-data/myki-csv/user-account.csv.ts | 1 - .../importers/spec-data/myki-csv/user-credit-card.csv.ts | 1 - .../src/importers/spec-data/myki-csv/user-id-card.csv.ts | 1 - .../src/importers/spec-data/myki-csv/user-identity.csv.ts | 1 - .../src/importers/spec-data/myki-csv/user-note.csv.ts | 1 - .../src/importers/spec-data/myki-csv/user-twofa.csv.ts | 1 - libs/key-management/src/key.service.ts | 1 - libs/vault/src/cipher-form/cipher-form.stories.ts | 2 +- 69 files changed, 12 insertions(+), 91 deletions(-) diff --git a/apps/browser/postcss.config.js b/apps/browser/postcss.config.js index a4dee9d436..5657df3afc 100644 --- a/apps/browser/postcss.config.js +++ b/apps/browser/postcss.config.js @@ -1,4 +1,4 @@ -/* eslint-disable no-undef, @typescript-eslint/no-require-imports */ +/* eslint-disable @typescript-eslint/no-require-imports */ module.exports = { plugins: [ require("postcss-import"), diff --git a/apps/browser/src/auth/popup/settings/account-security.component.ts b/apps/browser/src/auth/popup/settings/account-security.component.ts index 871d1b3014..8cdfdab952 100644 --- a/apps/browser/src/auth/popup/settings/account-security.component.ts +++ b/apps/browser/src/auth/popup/settings/account-security.component.ts @@ -99,7 +99,6 @@ import { AwaitDesktopDialogComponent } from "./await-desktop-dialog.component"; VaultTimeoutInputComponent, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class AccountSecurityComponent implements OnInit, OnDestroy { protected readonly VaultTimeoutAction = VaultTimeoutAction; diff --git a/apps/browser/src/autofill/deprecated/background/overlay.background.deprecated.spec.ts b/apps/browser/src/autofill/deprecated/background/overlay.background.deprecated.spec.ts index 497664542a..d5541b5da4 100644 --- a/apps/browser/src/autofill/deprecated/background/overlay.background.deprecated.spec.ts +++ b/apps/browser/src/autofill/deprecated/background/overlay.background.deprecated.spec.ts @@ -479,7 +479,6 @@ describe("OverlayBackground", () => { it("will set up onMessage and onConnect listeners", () => { overlayBackground["setupExtensionMessageListeners"](); - // eslint-disable-next-line expect(chrome.runtime.onMessage.addListener).toHaveBeenCalled(); expect(chrome.runtime.onConnect.addListener).toHaveBeenCalled(); }); diff --git a/apps/browser/src/autofill/services/autofill.service.ts b/apps/browser/src/autofill/services/autofill.service.ts index 72df679294..e833420b85 100644 --- a/apps/browser/src/autofill/services/autofill.service.ts +++ b/apps/browser/src/autofill/services/autofill.service.ts @@ -1412,7 +1412,6 @@ export default class AutofillService implements AutofillServiceInterface { let doesContainValue = false; CreditCardAutoFillConstants.CardAttributesExtended.forEach((attributeName) => { - // eslint-disable-next-line no-prototype-builtins if (doesContainValue || !field[attributeName]) { return; } diff --git a/apps/browser/src/background/idle.background.ts b/apps/browser/src/background/idle.background.ts index 8dccc93337..90276eaea0 100644 --- a/apps/browser/src/background/idle.background.ts +++ b/apps/browser/src/background/idle.background.ts @@ -34,12 +34,8 @@ export default class IdleBackground { const idleHandler = (newState: string) => { if (newState === "active") { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.notificationsService.reconnectFromActivity(); } else { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.notificationsService.disconnectFromInactivity(); } }; diff --git a/apps/browser/src/platform/services/task-scheduler/browser-task-scheduler.service.spec.ts b/apps/browser/src/platform/services/task-scheduler/browser-task-scheduler.service.spec.ts index d72ba94205..0c85e8a8e4 100644 --- a/apps/browser/src/platform/services/task-scheduler/browser-task-scheduler.service.spec.ts +++ b/apps/browser/src/platform/services/task-scheduler/browser-task-scheduler.service.spec.ts @@ -85,7 +85,6 @@ describe("BrowserTaskSchedulerService", () => { callback, ); // @ts-expect-error mocking global browser object - // eslint-disable-next-line no-global-assign globalThis.browser = {}; chrome.alarms.get = jest.fn().mockImplementation((_name, callback) => callback(undefined)); }); @@ -95,8 +94,7 @@ describe("BrowserTaskSchedulerService", () => { jest.clearAllTimers(); jest.useRealTimers(); - // eslint-disable-next-line no-global-assign - globalThis.browser = undefined; + (globalThis.browser as any) = undefined; }); describe("setTimeout", () => { diff --git a/apps/browser/tailwind.config.js b/apps/browser/tailwind.config.js index f0a7db8e8b..02e1d86f5a 100644 --- a/apps/browser/tailwind.config.js +++ b/apps/browser/tailwind.config.js @@ -1,4 +1,4 @@ -/* eslint-disable no-undef, @typescript-eslint/no-require-imports */ +/* eslint-disable @typescript-eslint/no-require-imports */ const config = require("../../libs/components/tailwind.config.base"); config.content = [ diff --git a/apps/cli/src/commands/get.command.ts b/apps/cli/src/commands/get.command.ts index eea63fdfc7..28c06505f8 100644 --- a/apps/cli/src/commands/get.command.ts +++ b/apps/cli/src/commands/get.command.ts @@ -571,7 +571,7 @@ export class GetCommand extends DownloadCommand { const pubKey = Utils.fromB64ToArray(response.publicKey); fingerprint = await this.keyService.getFingerprint(id, pubKey); } catch { - // eslint-disable-next-line + // empty - handled by the null check below } } diff --git a/apps/desktop/postcss.config.js b/apps/desktop/postcss.config.js index 05e2b04124..5657df3afc 100644 --- a/apps/desktop/postcss.config.js +++ b/apps/desktop/postcss.config.js @@ -1,4 +1,4 @@ -/* eslint-disable @typescript-eslint/no-require-imports, no-undef */ +/* eslint-disable @typescript-eslint/no-require-imports */ module.exports = { plugins: [ require("postcss-import"), diff --git a/apps/desktop/src/app/accounts/settings.component.ts b/apps/desktop/src/app/accounts/settings.component.ts index 51d1f4cfa4..d478796b75 100644 --- a/apps/desktop/src/app/accounts/settings.component.ts +++ b/apps/desktop/src/app/accounts/settings.component.ts @@ -53,7 +53,6 @@ import { NativeMessagingManifestService } from "../services/native-messaging-man selector: "app-settings", templateUrl: "settings.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class SettingsComponent implements OnInit, OnDestroy { // For use in template protected readonly VaultTimeoutAction = VaultTimeoutAction; diff --git a/apps/desktop/src/app/app.component.ts b/apps/desktop/src/app/app.component.ts index ea18617daf..85c159f027 100644 --- a/apps/desktop/src/app/app.component.ts +++ b/apps/desktop/src/app/app.component.ts @@ -719,12 +719,8 @@ export class AppComponent implements OnInit, OnDestroy { private idleStateChanged() { if (this.isIdle) { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.notificationsService.disconnectFromInactivity(); } else { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.notificationsService.reconnectFromActivity(); } } diff --git a/apps/desktop/src/auth/two-factor-v1.component.ts b/apps/desktop/src/auth/two-factor-v1.component.ts index 26a6f81b88..3980e944df 100644 --- a/apps/desktop/src/auth/two-factor-v1.component.ts +++ b/apps/desktop/src/auth/two-factor-v1.component.ts @@ -37,7 +37,6 @@ const BroadcasterSubscriptionId = "TwoFactorComponent"; selector: "app-two-factor", templateUrl: "two-factor-v1.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class TwoFactorComponentV1 extends BaseTwoFactorComponent implements OnDestroy { @ViewChild("twoFactorOptions", { read: ViewContainerRef, static: true }) twoFactorOptionsModal: ViewContainerRef; diff --git a/apps/desktop/src/main/window.main.ts b/apps/desktop/src/main/window.main.ts index e05ce10067..069d1aae32 100644 --- a/apps/desktop/src/main/window.main.ts +++ b/apps/desktop/src/main/window.main.ts @@ -91,7 +91,6 @@ export class WindowMain { app.quit(); return; } else { - // eslint-disable-next-line app.on("second-instance", (event, argv, workingDirectory) => { // Someone tried to run a second instance, we should focus our window. if (this.win != null) { diff --git a/apps/desktop/src/platform/services/electron-key.service.ts b/apps/desktop/src/platform/services/electron-key.service.ts index dceb1dea08..60caba4a3a 100644 --- a/apps/desktop/src/platform/services/electron-key.service.ts +++ b/apps/desktop/src/platform/services/electron-key.service.ts @@ -57,8 +57,6 @@ export class ElectronKeyService extends DefaultKeyService { } override async clearStoredUserKey(keySuffix: KeySuffixOptions, userId?: UserId): Promise { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises await super.clearStoredUserKey(keySuffix, userId); } diff --git a/apps/desktop/src/vault/app/vault/vault-items.component.ts b/apps/desktop/src/vault/app/vault/vault-items.component.ts index 5d7285e570..b7a45bd246 100644 --- a/apps/desktop/src/vault/app/vault/vault-items.component.ts +++ b/apps/desktop/src/vault/app/vault/vault-items.component.ts @@ -15,7 +15,6 @@ import { SearchBarService } from "../../../app/layout/search/search-bar.service" selector: "app-vault-items", templateUrl: "vault-items.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class VaultItemsComponent extends BaseVaultItemsComponent { constructor( searchService: SearchService, diff --git a/apps/desktop/tailwind.config.js b/apps/desktop/tailwind.config.js index 50e5799bc6..5b4cab027b 100644 --- a/apps/desktop/tailwind.config.js +++ b/apps/desktop/tailwind.config.js @@ -1,4 +1,4 @@ -/* eslint-disable no-undef, @typescript-eslint/no-require-imports */ +/* eslint-disable @typescript-eslint/no-require-imports */ const config = require("../../libs/components/tailwind.config.base"); config.content = [ diff --git a/apps/web/postcss.config.js b/apps/web/postcss.config.js index 05e2b04124..5657df3afc 100644 --- a/apps/web/postcss.config.js +++ b/apps/web/postcss.config.js @@ -1,4 +1,4 @@ -/* eslint-disable @typescript-eslint/no-require-imports, no-undef */ +/* eslint-disable @typescript-eslint/no-require-imports */ module.exports = { plugins: [ require("postcss-import"), diff --git a/apps/web/src/app/admin-console/organizations/members/members.component.ts b/apps/web/src/app/admin-console/organizations/members/members.component.ts index df4517942f..0bfdde8fc9 100644 --- a/apps/web/src/app/admin-console/organizations/members/members.component.ts +++ b/apps/web/src/app/admin-console/organizations/members/members.component.ts @@ -663,9 +663,6 @@ export class MembersComponent extends BaseMembersComponent this.organization.id, filteredUsers.map((user) => user.id), ); - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises - // Bulk Status component open const dialogRef = BulkStatusComponent.open(this.dialogService, { data: { diff --git a/apps/web/src/app/admin-console/organizations/policies/policies.component.ts b/apps/web/src/app/admin-console/organizations/policies/policies.component.ts index 3354c7c5e1..52cb4da107 100644 --- a/apps/web/src/app/admin-console/organizations/policies/policies.component.ts +++ b/apps/web/src/app/admin-console/organizations/policies/policies.component.ts @@ -25,7 +25,6 @@ import { PolicyEditComponent, PolicyEditDialogResult } from "./policy-edit.compo selector: "app-org-policies", templateUrl: "policies.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class PoliciesComponent implements OnInit { @ViewChild("editTemplate", { read: ViewContainerRef, static: true }) editModalRef: ViewContainerRef; diff --git a/apps/web/src/app/admin-console/organizations/settings/two-factor-setup.component.ts b/apps/web/src/app/admin-console/organizations/settings/two-factor-setup.component.ts index 323e5326a1..7099b90baa 100644 --- a/apps/web/src/app/admin-console/organizations/settings/two-factor-setup.component.ts +++ b/apps/web/src/app/admin-console/organizations/settings/two-factor-setup.component.ts @@ -31,7 +31,6 @@ import { TwoFactorVerifyComponent } from "../../../auth/settings/two-factor/two- selector: "app-two-factor-setup", templateUrl: "../../../auth/settings/two-factor/two-factor-setup.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class TwoFactorSetupComponent extends BaseTwoFactorSetupComponent implements OnInit { tabbedHeader = false; constructor( diff --git a/apps/web/src/app/app.component.ts b/apps/web/src/app/app.component.ts index bc41e0f99f..9d2afb2268 100644 --- a/apps/web/src/app/app.component.ts +++ b/apps/web/src/app/app.component.ts @@ -173,8 +173,6 @@ export class AppComponent implements OnDestroy, OnInit { type: "success", }); if (premiumConfirmed) { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises await this.router.navigate(["settings/subscription/premium"]); } break; @@ -359,12 +357,8 @@ export class AppComponent implements OnDestroy, OnInit { private idleStateChanged() { if (this.isIdle) { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.notificationsService.disconnectFromInactivity(); } else { - // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.notificationsService.reconnectFromActivity(); } } diff --git a/apps/web/src/app/auth/login/login-v1.component.ts b/apps/web/src/app/auth/login/login-v1.component.ts index a3099d991d..247aee4828 100644 --- a/apps/web/src/app/auth/login/login-v1.component.ts +++ b/apps/web/src/app/auth/login/login-v1.component.ts @@ -40,7 +40,6 @@ import { OrganizationInvite } from "../organization-invite/organization-invite"; selector: "app-login", templateUrl: "login-v1.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class LoginComponentV1 extends BaseLoginComponent implements OnInit { showResetPasswordAutoEnrollWarning = false; enforcedPasswordPolicyOptions: MasterPasswordPolicyOptions; diff --git a/apps/web/src/app/auth/settings/emergency-access/emergency-access.component.ts b/apps/web/src/app/auth/settings/emergency-access/emergency-access.component.ts index 83bdfffbe4..dc464c1805 100644 --- a/apps/web/src/app/auth/settings/emergency-access/emergency-access.component.ts +++ b/apps/web/src/app/auth/settings/emergency-access/emergency-access.component.ts @@ -43,7 +43,6 @@ import { selector: "emergency-access", templateUrl: "emergency-access.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class EmergencyAccessComponent implements OnInit { @ViewChild("addEdit", { read: ViewContainerRef, static: true }) addEditModalRef: ViewContainerRef; @ViewChild("takeoverTemplate", { read: ViewContainerRef, static: true }) diff --git a/apps/web/src/app/auth/settings/emergency-access/takeover/emergency-access-takeover.component.ts b/apps/web/src/app/auth/settings/emergency-access/takeover/emergency-access-takeover.component.ts index 5747386cf8..5ac7d66d33 100644 --- a/apps/web/src/app/auth/settings/emergency-access/takeover/emergency-access-takeover.component.ts +++ b/apps/web/src/app/auth/settings/emergency-access/takeover/emergency-access-takeover.component.ts @@ -33,7 +33,6 @@ type EmergencyAccessTakeoverDialogData = { selector: "emergency-access-takeover", templateUrl: "emergency-access-takeover.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class EmergencyAccessTakeoverComponent extends ChangePasswordComponent implements OnInit, OnDestroy @@ -86,7 +85,6 @@ export class EmergencyAccessTakeoverComponent .subscribe((enforcedPolicyOptions) => (this.enforcedPolicyOptions = enforcedPolicyOptions)); } - // eslint-disable-next-line rxjs-angular/prefer-takeuntil ngOnDestroy(): void { super.ngOnDestroy(); } diff --git a/apps/web/src/app/auth/settings/emergency-access/view/emergency-access-view.component.ts b/apps/web/src/app/auth/settings/emergency-access/view/emergency-access-view.component.ts index dc283c9931..1e3d0cf705 100644 --- a/apps/web/src/app/auth/settings/emergency-access/view/emergency-access-view.component.ts +++ b/apps/web/src/app/auth/settings/emergency-access/view/emergency-access-view.component.ts @@ -18,7 +18,6 @@ import { EmergencyViewDialogComponent } from "./emergency-view-dialog.component" templateUrl: "emergency-access-view.component.html", providers: [{ provide: CipherFormConfigService, useClass: DefaultCipherFormConfigService }], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class EmergencyAccessViewComponent implements OnInit { @ViewChild("attachments", { read: ViewContainerRef, static: true }) attachmentsModalRef: ViewContainerRef; diff --git a/apps/web/src/app/auth/sso-v1.component.ts b/apps/web/src/app/auth/sso-v1.component.ts index 8699ecf7b2..42cd8301fa 100644 --- a/apps/web/src/app/auth/sso-v1.component.ts +++ b/apps/web/src/app/auth/sso-v1.component.ts @@ -37,7 +37,6 @@ import { PasswordGenerationServiceAbstraction } from "@bitwarden/generator-legac selector: "app-sso", templateUrl: "sso-v1.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class SsoComponentV1 extends BaseSsoComponent implements OnInit { protected formGroup = new FormGroup({ identifier: new FormControl(null, [Validators.required]), diff --git a/apps/web/src/app/auth/two-factor-v1.component.ts b/apps/web/src/app/auth/two-factor-v1.component.ts index adaa735eca..86b67fa7bb 100644 --- a/apps/web/src/app/auth/two-factor-v1.component.ts +++ b/apps/web/src/app/auth/two-factor-v1.component.ts @@ -37,7 +37,6 @@ import { selector: "app-two-factor", templateUrl: "two-factor-v1.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class TwoFactorComponentV1 extends BaseTwoFactorComponent implements OnInit, OnDestroy { @ViewChild("twoFactorOptions", { read: ViewContainerRef, static: true }) twoFactorOptionsModal: ViewContainerRef; diff --git a/apps/web/src/app/auth/verify-email-token.component.ts b/apps/web/src/app/auth/verify-email-token.component.ts index 4ed5369773..55569f44c1 100644 --- a/apps/web/src/app/auth/verify-email-token.component.ts +++ b/apps/web/src/app/auth/verify-email-token.component.ts @@ -16,7 +16,6 @@ import { ToastService } from "@bitwarden/components"; selector: "app-verify-email-token", templateUrl: "verify-email-token.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class VerifyEmailTokenComponent implements OnInit { constructor( private router: Router, diff --git a/apps/web/src/app/auth/verify-recover-delete.component.ts b/apps/web/src/app/auth/verify-recover-delete.component.ts index 725f012bf5..8d95dd01b7 100644 --- a/apps/web/src/app/auth/verify-recover-delete.component.ts +++ b/apps/web/src/app/auth/verify-recover-delete.component.ts @@ -15,7 +15,6 @@ import { ToastService } from "@bitwarden/components"; selector: "app-verify-recover-delete", templateUrl: "verify-recover-delete.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class VerifyRecoverDeleteComponent implements OnInit { email: string; diff --git a/apps/web/src/app/billing/shared/payment-method.component.ts b/apps/web/src/app/billing/shared/payment-method.component.ts index dc031ade42..113a0eab6c 100644 --- a/apps/web/src/app/billing/shared/payment-method.component.ts +++ b/apps/web/src/app/billing/shared/payment-method.component.ts @@ -36,7 +36,6 @@ import { @Component({ templateUrl: "payment-method.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class PaymentMethodComponent implements OnInit, OnDestroy { loading = false; firstLoaded = false; diff --git a/apps/web/src/app/billing/shared/tax-info.component.ts b/apps/web/src/app/billing/shared/tax-info.component.ts index a987ed8d48..74e2ab35cb 100644 --- a/apps/web/src/app/billing/shared/tax-info.component.ts +++ b/apps/web/src/app/billing/shared/tax-info.component.ts @@ -24,7 +24,6 @@ import { SharedModule } from "../../shared"; standalone: true, imports: [SharedModule], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class TaxInfoComponent implements OnInit, OnDestroy { private destroy$ = new Subject(); @@ -91,7 +90,7 @@ export class TaxInfoComponent implements OnInit, OnDestroy { async ngOnInit() { // Provider setup - // eslint-disable-next-line rxjs-angular/prefer-takeuntil, rxjs/no-async-subscribe + // eslint-disable-next-line rxjs-angular/prefer-takeuntil this.route.queryParams.subscribe((params) => { this.providerId = params.providerId; }); diff --git a/apps/web/src/app/core/core.module.ts b/apps/web/src/app/core/core.module.ts index c835e504b5..7ba10ed919 100644 --- a/apps/web/src/app/core/core.module.ts +++ b/apps/web/src/app/core/core.module.ts @@ -82,7 +82,6 @@ import { } from "@bitwarden/common/platform/notifications/internal"; import { AppIdService as DefaultAppIdService } from "@bitwarden/common/platform/services/app-id.service"; import { MemoryStorageService } from "@bitwarden/common/platform/services/memory-storage.service"; -// eslint-disable-next-line import/no-restricted-paths -- Implementation for memory storage import { MigrationBuilderService } from "@bitwarden/common/platform/services/migration-builder.service"; import { MigrationRunner } from "@bitwarden/common/platform/services/migration-runner"; import { DefaultSdkClientFactory } from "@bitwarden/common/platform/services/sdk/default-sdk-client-factory"; diff --git a/apps/web/src/app/tools/reports/pages/breach-report.component.spec.ts b/apps/web/src/app/tools/reports/pages/breach-report.component.spec.ts index 0edde21061..9af15749a9 100644 --- a/apps/web/src/app/tools/reports/pages/breach-report.component.spec.ts +++ b/apps/web/src/app/tools/reports/pages/breach-report.component.spec.ts @@ -1,6 +1,5 @@ // FIXME: Update this file to be type safe and remove this and next line // @ts-strict-ignore -// eslint-disable-next-line no-restricted-imports import { ComponentFixture, TestBed } from "@angular/core/testing"; import { ReactiveFormsModule } from "@angular/forms"; import { mock, MockProxy } from "jest-mock-extended"; diff --git a/apps/web/src/app/tools/reports/pages/exposed-passwords-report.component.spec.ts b/apps/web/src/app/tools/reports/pages/exposed-passwords-report.component.spec.ts index cf7d8bcb05..052e3bc7cf 100644 --- a/apps/web/src/app/tools/reports/pages/exposed-passwords-report.component.spec.ts +++ b/apps/web/src/app/tools/reports/pages/exposed-passwords-report.component.spec.ts @@ -1,4 +1,3 @@ -// eslint-disable-next-line no-restricted-imports import { ComponentFixture, TestBed } from "@angular/core/testing"; import { mock, MockProxy } from "jest-mock-extended"; import { of } from "rxjs"; diff --git a/apps/web/src/app/tools/reports/pages/inactive-two-factor-report.component.spec.ts b/apps/web/src/app/tools/reports/pages/inactive-two-factor-report.component.spec.ts index fb378b0984..acc3423257 100644 --- a/apps/web/src/app/tools/reports/pages/inactive-two-factor-report.component.spec.ts +++ b/apps/web/src/app/tools/reports/pages/inactive-two-factor-report.component.spec.ts @@ -1,4 +1,3 @@ -// eslint-disable-next-line no-restricted-imports import { ComponentFixture, TestBed } from "@angular/core/testing"; import { MockProxy, mock } from "jest-mock-extended"; import { of } from "rxjs"; diff --git a/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts index 2722e66f14..4f0988082b 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/exposed-passwords-report.component.ts @@ -19,7 +19,6 @@ import { CipherView } from "@bitwarden/common/vault/models/view/cipher.view"; import { DialogService } from "@bitwarden/components"; import { PasswordRepromptService, CipherFormConfigService } from "@bitwarden/vault"; -// eslint-disable-next-line no-restricted-imports import { RoutedVaultFilterBridgeService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter-bridge.service"; import { RoutedVaultFilterService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter.service"; import { AdminConsoleCipherFormConfigService } from "../../../../vault/org-vault/services/admin-console-cipher-form-config.service"; @@ -38,7 +37,6 @@ import { ExposedPasswordsReportComponent as BaseExposedPasswordsReportComponent RoutedVaultFilterBridgeService, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class ExposedPasswordsReportComponent extends BaseExposedPasswordsReportComponent implements OnInit diff --git a/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts index 9b53d583b9..6dc202de0b 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/inactive-two-factor-report.component.ts @@ -18,7 +18,6 @@ import { CipherView } from "@bitwarden/common/vault/models/view/cipher.view"; import { DialogService } from "@bitwarden/components"; import { CipherFormConfigService, PasswordRepromptService } from "@bitwarden/vault"; -// eslint-disable-next-line no-restricted-imports import { RoutedVaultFilterBridgeService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter-bridge.service"; import { RoutedVaultFilterService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter.service"; import { AdminConsoleCipherFormConfigService } from "../../../../vault/org-vault/services/admin-console-cipher-form-config.service"; @@ -37,7 +36,6 @@ import { InactiveTwoFactorReportComponent as BaseInactiveTwoFactorReportComponen RoutedVaultFilterBridgeService, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class InactiveTwoFactorReportComponent extends BaseInactiveTwoFactorReportComponent implements OnInit diff --git a/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts index bcd573fb09..4e37f53ba6 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/reused-passwords-report.component.ts @@ -18,7 +18,6 @@ import { CipherView } from "@bitwarden/common/vault/models/view/cipher.view"; import { DialogService } from "@bitwarden/components"; import { CipherFormConfigService, PasswordRepromptService } from "@bitwarden/vault"; -// eslint-disable-next-line no-restricted-imports import { RoutedVaultFilterBridgeService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter-bridge.service"; import { RoutedVaultFilterService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter.service"; import { AdminConsoleCipherFormConfigService } from "../../../../vault/org-vault/services/admin-console-cipher-form-config.service"; @@ -37,7 +36,6 @@ import { ReusedPasswordsReportComponent as BaseReusedPasswordsReportComponent } RoutedVaultFilterBridgeService, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class ReusedPasswordsReportComponent extends BaseReusedPasswordsReportComponent implements OnInit diff --git a/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts index e653a6b9a0..25e1314fce 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/unsecured-websites-report.component.ts @@ -18,7 +18,6 @@ import { CipherView } from "@bitwarden/common/vault/models/view/cipher.view"; import { DialogService } from "@bitwarden/components"; import { CipherFormConfigService, PasswordRepromptService } from "@bitwarden/vault"; -// eslint-disable-next-line no-restricted-imports import { RoutedVaultFilterBridgeService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter-bridge.service"; import { RoutedVaultFilterService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter.service"; import { AdminConsoleCipherFormConfigService } from "../../../../vault/org-vault/services/admin-console-cipher-form-config.service"; @@ -37,7 +36,6 @@ import { UnsecuredWebsitesReportComponent as BaseUnsecuredWebsitesReportComponen RoutedVaultFilterBridgeService, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class UnsecuredWebsitesReportComponent extends BaseUnsecuredWebsitesReportComponent implements OnInit diff --git a/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts b/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts index 41018d69c2..ef9bd97008 100644 --- a/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts +++ b/apps/web/src/app/tools/reports/pages/organizations/weak-passwords-report.component.ts @@ -19,7 +19,6 @@ import { CipherView } from "@bitwarden/common/vault/models/view/cipher.view"; import { DialogService } from "@bitwarden/components"; import { CipherFormConfigService, PasswordRepromptService } from "@bitwarden/vault"; -// eslint-disable-next-line no-restricted-imports import { RoutedVaultFilterBridgeService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter-bridge.service"; import { RoutedVaultFilterService } from "../../../../vault/individual-vault/vault-filter/services/routed-vault-filter.service"; import { AdminConsoleCipherFormConfigService } from "../../../../vault/org-vault/services/admin-console-cipher-form-config.service"; @@ -38,7 +37,6 @@ import { WeakPasswordsReportComponent as BaseWeakPasswordsReportComponent } from RoutedVaultFilterBridgeService, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class WeakPasswordsReportComponent extends BaseWeakPasswordsReportComponent implements OnInit diff --git a/apps/web/src/app/tools/reports/pages/reused-passwords-report.component.spec.ts b/apps/web/src/app/tools/reports/pages/reused-passwords-report.component.spec.ts index b0232225d6..5933d2ce29 100644 --- a/apps/web/src/app/tools/reports/pages/reused-passwords-report.component.spec.ts +++ b/apps/web/src/app/tools/reports/pages/reused-passwords-report.component.spec.ts @@ -1,4 +1,3 @@ -// eslint-disable-next-line no-restricted-imports import { ComponentFixture, TestBed } from "@angular/core/testing"; import { MockProxy, mock } from "jest-mock-extended"; import { of } from "rxjs"; diff --git a/apps/web/src/app/tools/reports/pages/unsecured-websites-report.component.spec.ts b/apps/web/src/app/tools/reports/pages/unsecured-websites-report.component.spec.ts index c0ae8d53c9..040d73a0d6 100644 --- a/apps/web/src/app/tools/reports/pages/unsecured-websites-report.component.spec.ts +++ b/apps/web/src/app/tools/reports/pages/unsecured-websites-report.component.spec.ts @@ -1,4 +1,3 @@ -// eslint-disable-next-line no-restricted-imports import { ComponentFixture, TestBed } from "@angular/core/testing"; import { MockProxy, mock } from "jest-mock-extended"; import { of } from "rxjs"; diff --git a/apps/web/src/app/tools/reports/pages/weak-passwords-report.component.spec.ts b/apps/web/src/app/tools/reports/pages/weak-passwords-report.component.spec.ts index ab202bffb5..d78dc7e3ce 100644 --- a/apps/web/src/app/tools/reports/pages/weak-passwords-report.component.spec.ts +++ b/apps/web/src/app/tools/reports/pages/weak-passwords-report.component.spec.ts @@ -1,4 +1,3 @@ -// eslint-disable-next-line no-restricted-imports import { ComponentFixture, TestBed } from "@angular/core/testing"; import { mock, MockProxy } from "jest-mock-extended"; import { of } from "rxjs"; diff --git a/apps/web/src/app/tools/send/send-access/access.component.ts b/apps/web/src/app/tools/send/send-access/access.component.ts index a2922914ba..6bed32e97d 100644 --- a/apps/web/src/app/tools/send/send-access/access.component.ts +++ b/apps/web/src/app/tools/send/send-access/access.component.ts @@ -39,7 +39,6 @@ import { SendAccessTextComponent } from "./send-access-text.component"; NoItemsModule, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class AccessComponent implements OnInit { protected send: SendAccessView; protected sendType = SendType; diff --git a/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/domain-verification/domain-verification.component.ts b/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/domain-verification/domain-verification.component.ts index 1cbe57a708..70823d61c3 100644 --- a/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/domain-verification/domain-verification.component.ts +++ b/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/domain-verification/domain-verification.component.ts @@ -61,7 +61,6 @@ export class DomainVerificationComponent implements OnInit, OnDestroy { ); } - // eslint-disable-next-line @typescript-eslint/no-empty-function async ngOnInit() { this.orgDomains$ = this.orgDomainService.orgDomains$; diff --git a/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/scim.component.ts b/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/scim.component.ts index ea24e74ac8..76bcd7383f 100644 --- a/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/scim.component.ts +++ b/bitwarden_license/bit-web/src/app/admin-console/organizations/manage/scim.component.ts @@ -25,7 +25,6 @@ import { DialogService, ToastService } from "@bitwarden/components"; selector: "app-org-manage-scim", templateUrl: "scim.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class ScimComponent implements OnInit { loading = true; organizationId: string; diff --git a/bitwarden_license/bit-web/src/app/admin-console/providers/clients/create-organization.component.ts b/bitwarden_license/bit-web/src/app/admin-console/providers/clients/create-organization.component.ts index ec35274806..d22665b432 100644 --- a/bitwarden_license/bit-web/src/app/admin-console/providers/clients/create-organization.component.ts +++ b/bitwarden_license/bit-web/src/app/admin-console/providers/clients/create-organization.component.ts @@ -9,7 +9,6 @@ import { OrganizationPlansComponent } from "@bitwarden/web-vault/app/billing"; selector: "app-create-organization", templateUrl: "create-organization.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class CreateOrganizationComponent implements OnInit { @ViewChild(OrganizationPlansComponent, { static: true }) orgPlansComponent: OrganizationPlansComponent; diff --git a/bitwarden_license/bit-web/src/app/admin-console/providers/manage/events.component.ts b/bitwarden_license/bit-web/src/app/admin-console/providers/manage/events.component.ts index 6390d13ee1..87f29fd91e 100644 --- a/bitwarden_license/bit-web/src/app/admin-console/providers/manage/events.component.ts +++ b/bitwarden_license/bit-web/src/app/admin-console/providers/manage/events.component.ts @@ -20,7 +20,6 @@ import { EventExportService } from "@bitwarden/web-vault/app/tools/event-export" selector: "provider-events", templateUrl: "events.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class EventsComponent extends BaseEventsComponent implements OnInit { exportFileName = "provider-events"; providerId: string; diff --git a/bitwarden_license/bit-web/src/app/admin-console/providers/settings/account.component.ts b/bitwarden_license/bit-web/src/app/admin-console/providers/settings/account.component.ts index e0a4eaedce..e72e1c7c32 100644 --- a/bitwarden_license/bit-web/src/app/admin-console/providers/settings/account.component.ts +++ b/bitwarden_license/bit-web/src/app/admin-console/providers/settings/account.component.ts @@ -21,7 +21,6 @@ import { DialogService, ToastService } from "@bitwarden/components"; selector: "provider-account", templateUrl: "account.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class AccountComponent implements OnDestroy, OnInit { selfHosted = false; loading = true; diff --git a/bitwarden_license/bit-web/src/app/admin-console/providers/verify-recover-delete-provider.component.ts b/bitwarden_license/bit-web/src/app/admin-console/providers/verify-recover-delete-provider.component.ts index 83a87d8bc6..b27a7ddd0f 100644 --- a/bitwarden_license/bit-web/src/app/admin-console/providers/verify-recover-delete-provider.component.ts +++ b/bitwarden_license/bit-web/src/app/admin-console/providers/verify-recover-delete-provider.component.ts @@ -14,7 +14,6 @@ import { ToastService } from "@bitwarden/components"; selector: "app-verify-recover-delete-provider", templateUrl: "verify-recover-delete-provider.component.html", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class VerifyRecoverDeleteProviderComponent implements OnInit { name: string; diff --git a/bitwarden_license/bit-web/src/app/tools/access-intelligence/risk-insights.component.ts b/bitwarden_license/bit-web/src/app/tools/access-intelligence/risk-insights.component.ts index 20dc320de2..68ec7bb249 100644 --- a/bitwarden_license/bit-web/src/app/tools/access-intelligence/risk-insights.component.ts +++ b/bitwarden_license/bit-web/src/app/tools/access-intelligence/risk-insights.component.ts @@ -15,7 +15,6 @@ import { DrawerType, PasswordHealthReportApplicationsResponse, } from "@bitwarden/bit-common/tools/reports/risk-insights/models/password-health"; -// eslint-disable-next-line no-restricted-imports -- used for dependency injection import { FeatureFlag } from "@bitwarden/common/enums/feature-flag.enum"; import { ConfigService } from "@bitwarden/common/platform/abstractions/config/config.service"; import { devFlagEnabled } from "@bitwarden/common/platform/misc/flags"; diff --git a/eslint.config.mjs b/eslint.config.mjs index 2d7c91521f..9d93d1118c 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -27,6 +27,9 @@ export default tseslint.config( importPlugin.flatConfigs.typescript, eslintConfigPrettier, // Disables rules that conflict with Prettier ], + linterOptions: { + reportUnusedDisableDirectives: "error", + }, plugins: { rxjs: rxjs, "rxjs-angular": angularRxjs, diff --git a/libs/angular/src/auth/components/login-via-auth-request-v1.component.ts b/libs/angular/src/auth/components/login-via-auth-request-v1.component.ts index 7409acf684..7f5a5c3f29 100644 --- a/libs/angular/src/auth/components/login-via-auth-request-v1.component.ts +++ b/libs/angular/src/auth/components/login-via-auth-request-v1.component.ts @@ -107,7 +107,6 @@ export class LoginViaAuthRequestComponentV1 this.authRequestService.authRequestPushNotification$ .pipe(takeUntil(this.destroy$)) .subscribe((id) => { - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.verifyAndHandleApprovedAuthReq(id).catch((e: Error) => { this.toastService.showToast({ variant: "error", diff --git a/libs/angular/src/auth/components/two-factor-v1.component.spec.ts b/libs/angular/src/auth/components/two-factor-v1.component.spec.ts index 82dea7cd8c..ccbd8e18a6 100644 --- a/libs/angular/src/auth/components/two-factor-v1.component.spec.ts +++ b/libs/angular/src/auth/components/two-factor-v1.component.spec.ts @@ -4,7 +4,6 @@ import { ActivatedRoute, convertToParamMap, Router } from "@angular/router"; import { mock, MockProxy } from "jest-mock-extended"; import { BehaviorSubject } from "rxjs"; -// eslint-disable-next-line no-restricted-imports import { WINDOW } from "@bitwarden/angular/services/injection-tokens"; import { LoginStrategyServiceAbstraction, diff --git a/libs/angular/src/auth/components/two-factor-v1.component.ts b/libs/angular/src/auth/components/two-factor-v1.component.ts index 4cbaa9362f..1040916c36 100644 --- a/libs/angular/src/auth/components/two-factor-v1.component.ts +++ b/libs/angular/src/auth/components/two-factor-v1.component.ts @@ -6,7 +6,6 @@ import { ActivatedRoute, NavigationExtras, Router } from "@angular/router"; import { firstValueFrom } from "rxjs"; import { first } from "rxjs/operators"; -// eslint-disable-next-line no-restricted-imports import { WINDOW } from "@bitwarden/angular/services/injection-tokens"; import { LoginStrategyServiceAbstraction, diff --git a/libs/angular/src/auth/components/user-verification.component.ts b/libs/angular/src/auth/components/user-verification.component.ts index 7af53805a0..408d8403b8 100644 --- a/libs/angular/src/auth/components/user-verification.component.ts +++ b/libs/angular/src/auth/components/user-verification.component.ts @@ -23,7 +23,6 @@ import { KeyService } from "@bitwarden/key-management"; @Directive({ selector: "app-user-verification", }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class UserVerificationComponent implements ControlValueAccessor, OnInit, OnDestroy { private _invalidSecret = false; @Input() diff --git a/libs/auth/src/angular/two-factor-auth/two-factor-auth.component.spec.ts b/libs/auth/src/angular/two-factor-auth/two-factor-auth.component.spec.ts index 79856157aa..46b27a5aa4 100644 --- a/libs/auth/src/angular/two-factor-auth/two-factor-auth.component.spec.ts +++ b/libs/auth/src/angular/two-factor-auth/two-factor-auth.component.spec.ts @@ -6,7 +6,6 @@ import { ActivatedRoute, convertToParamMap, Router } from "@angular/router"; import { mock, MockProxy } from "jest-mock-extended"; import { BehaviorSubject } from "rxjs"; -// eslint-disable-next-line no-restricted-imports import { WINDOW } from "@bitwarden/angular/services/injection-tokens"; import { LoginStrategyServiceAbstraction, diff --git a/libs/auth/src/angular/user-verification/user-verification-form-input.component.ts b/libs/auth/src/angular/user-verification/user-verification-form-input.component.ts index 40c3106b18..ff4af51f73 100644 --- a/libs/auth/src/angular/user-verification/user-verification-form-input.component.ts +++ b/libs/auth/src/angular/user-verification/user-verification-form-input.component.ts @@ -68,7 +68,6 @@ import { ActiveClientVerificationOption } from "./active-client-verification-opt CalloutModule, ], }) -// eslint-disable-next-line rxjs-angular/prefer-takeuntil export class UserVerificationFormInputComponent implements ControlValueAccessor, OnInit, OnDestroy { @Input() verificationType: "server" | "client" = "server"; // server represents original behavior private _invalidSecret = false; diff --git a/libs/common/src/auth/models/request/identity-token/token.request.ts b/libs/common/src/auth/models/request/identity-token/token.request.ts index 390f184c06..497038878d 100644 --- a/libs/common/src/auth/models/request/identity-token/token.request.ts +++ b/libs/common/src/auth/models/request/identity-token/token.request.ts @@ -14,7 +14,6 @@ export abstract class TokenRequest { this.device = device != null ? device : null; } - // eslint-disable-next-line alterIdentityTokenHeaders(headers: Headers) { // Implemented in subclass if required } diff --git a/libs/common/src/state-migrations/migration-helper.spec.ts b/libs/common/src/state-migrations/migration-helper.spec.ts index 49e6e7fe9c..11126c6723 100644 --- a/libs/common/src/state-migrations/migration-helper.spec.ts +++ b/libs/common/src/state-migrations/migration-helper.spec.ts @@ -1,6 +1,5 @@ import { MockProxy, mock } from "jest-mock-extended"; -// eslint-disable-next-line import/no-restricted-paths -- Needed to print log messages import { FakeStorageService } from "../../spec/fake-storage.service"; // eslint-disable-next-line import/no-restricted-paths -- Needed client type enum import { ClientType } from "../enums"; diff --git a/libs/components/src/test.setup.ts b/libs/components/src/test.setup.ts index c7b9b1fdbf..6c54c8648e 100644 --- a/libs/components/src/test.setup.ts +++ b/libs/components/src/test.setup.ts @@ -1,5 +1,4 @@ // This file is required by karma.conf.js and loads recursively all the .spec and framework files -// eslint-disable-next-line import "zone.js/testing"; import { getTestBed } from "@angular/core/testing"; diff --git a/libs/importer/src/importers/spec-data/myki-csv/user-account.csv.ts b/libs/importer/src/importers/spec-data/myki-csv/user-account.csv.ts index 5ccf0971da..07b2597652 100644 --- a/libs/importer/src/importers/spec-data/myki-csv/user-account.csv.ts +++ b/libs/importer/src/importers/spec-data/myki-csv/user-account.csv.ts @@ -1,3 +1,2 @@ -/* eslint-disable */ export const userAccountData = `nickname,url,username,password,additionalInfo,twofaSecret,status,tags PasswordNickname,www.google.com,user.name@email.com,abc123,This is the additional information text.,someTOTPSeed,active,someTag`; diff --git a/libs/importer/src/importers/spec-data/myki-csv/user-credit-card.csv.ts b/libs/importer/src/importers/spec-data/myki-csv/user-credit-card.csv.ts index 0b127627ad..24cbec3a5b 100644 --- a/libs/importer/src/importers/spec-data/myki-csv/user-credit-card.csv.ts +++ b/libs/importer/src/importers/spec-data/myki-csv/user-credit-card.csv.ts @@ -1,3 +1,2 @@ -/* eslint-disable */ export const userCreditCardData = `nickname,status,tags,cardNumber,cardName,exp_month,exp_year,cvv,additionalInfo Visa test card,active,someTag,4111111111111111,Joe User,04,24,222,This is the additional information field`; diff --git a/libs/importer/src/importers/spec-data/myki-csv/user-id-card.csv.ts b/libs/importer/src/importers/spec-data/myki-csv/user-id-card.csv.ts index e1311d85bc..6fa6b6f737 100644 --- a/libs/importer/src/importers/spec-data/myki-csv/user-id-card.csv.ts +++ b/libs/importer/src/importers/spec-data/myki-csv/user-id-card.csv.ts @@ -1,4 +1,3 @@ -/* eslint-disable */ export const userIdCardData = `nickname,status,tags,idType,idNumber,idName,idIssuanceDate,idExpirationDate,idCountry,additionalInfo Joe User's nickname,active,someTag,Driver's License,123456,Joe M User,02/02/2022,02/02/2024,United States,Additional information Passport ID card,active,someTag,Passport,1234567,Joe M User,03/07/2022,03/07/2028,United States,Additional information field diff --git a/libs/importer/src/importers/spec-data/myki-csv/user-identity.csv.ts b/libs/importer/src/importers/spec-data/myki-csv/user-identity.csv.ts index 13afb16dae..c1938995d0 100644 --- a/libs/importer/src/importers/spec-data/myki-csv/user-identity.csv.ts +++ b/libs/importer/src/importers/spec-data/myki-csv/user-identity.csv.ts @@ -1,3 +1,2 @@ -/* eslint-disable */ export const userIdentityData = `nickname,status,tags,firstName,middleName,lastName,email,firstAddressLine,secondAddressLine,title,gender,number,city,country,zipCode,additionalInfo Joe User's nickname,active,someTag,Joe,M,User,joe.user@email.com,1 Example House,Suite 300,Mr,Male,2223334444,Portland,United States,04101,Additional information field`; diff --git a/libs/importer/src/importers/spec-data/myki-csv/user-note.csv.ts b/libs/importer/src/importers/spec-data/myki-csv/user-note.csv.ts index 8094c92f2a..66bd100550 100644 --- a/libs/importer/src/importers/spec-data/myki-csv/user-note.csv.ts +++ b/libs/importer/src/importers/spec-data/myki-csv/user-note.csv.ts @@ -1,3 +1,2 @@ -/* eslint-disable */ export const userNoteData = `nickname,status,content The title of a secure note,active,"The content of a secure note. Lorem ipsum, etc."`; diff --git a/libs/importer/src/importers/spec-data/myki-csv/user-twofa.csv.ts b/libs/importer/src/importers/spec-data/myki-csv/user-twofa.csv.ts index 68cfd44f38..0d0b0053bb 100644 --- a/libs/importer/src/importers/spec-data/myki-csv/user-twofa.csv.ts +++ b/libs/importer/src/importers/spec-data/myki-csv/user-twofa.csv.ts @@ -1,3 +1,2 @@ -/* eslint-disable */ export const userTwoFaData = `nickname,status,tags,authToken,additionalInfo 2FA nickname,active,someTag,someTOTPSeed,"Additional information field content. "`; diff --git a/libs/key-management/src/key.service.ts b/libs/key-management/src/key.service.ts index 129c33f1e8..bad827e4f5 100644 --- a/libs/key-management/src/key.service.ts +++ b/libs/key-management/src/key.service.ts @@ -260,7 +260,6 @@ export class DefaultKeyService implements KeyServiceAbstraction { } if (keySuffix === KeySuffixOptions.Pin && userId != null) { // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. - // eslint-disable-next-line @typescript-eslint/no-floating-promises this.pinService.clearPinKeyEncryptedUserKeyEphemeral(userId); // FIXME: Verify that this floating promise is intentional. If it is, add an explanatory comment and ensure there is proper error handling. // eslint-disable-next-line @typescript-eslint/no-floating-promises diff --git a/libs/vault/src/cipher-form/cipher-form.stories.ts b/libs/vault/src/cipher-form/cipher-form.stories.ts index 1af73b5a8b..fdcfa20032 100644 --- a/libs/vault/src/cipher-form/cipher-form.stories.ts +++ b/libs/vault/src/cipher-form/cipher-form.stories.ts @@ -36,7 +36,7 @@ import { } from "@bitwarden/vault"; // FIXME: remove `/apps` import from `/libs` // FIXME: remove `src` and fix import -// eslint-disable-next-line import/no-restricted-paths, no-restricted-imports +// eslint-disable-next-line no-restricted-imports import { PreloadedEnglishI18nModule } from "@bitwarden/web-vault/src/app/core/tests"; import { CipherFormService } from "./abstractions/cipher-form.service";