diff --git a/apps/desktop/src/app/services/services.module.ts b/apps/desktop/src/app/services/services.module.ts index 87fb1eecfc..c6fd004990 100644 --- a/apps/desktop/src/app/services/services.module.ts +++ b/apps/desktop/src/app/services/services.module.ts @@ -4,7 +4,6 @@ import { SECURE_STORAGE, STATE_FACTORY, STATE_SERVICE_USE_CACHE, - CLIENT_TYPE, LOCALES_DIRECTORY, SYSTEM_LANGUAGE, MEMORY_STORAGE, @@ -15,7 +14,6 @@ import { PolicyService as PolicyServiceAbstraction } from "@bitwarden/common/adm import { AuthService as AuthServiceAbstraction } from "@bitwarden/common/auth/abstractions/auth.service"; import { LoginService as LoginServiceAbstraction } from "@bitwarden/common/auth/abstractions/login.service"; import { LoginService } from "@bitwarden/common/auth/services/login.service"; -import { ClientType } from "@bitwarden/common/enums"; import { BroadcasterService as BroadcasterServiceAbstraction } from "@bitwarden/common/platform/abstractions/broadcaster.service"; import { CryptoFunctionService as CryptoFunctionServiceAbstraction } from "@bitwarden/common/platform/abstractions/crypto-function.service"; import { CryptoService as CryptoServiceAbstraction } from "@bitwarden/common/platform/abstractions/crypto.service"; @@ -82,10 +80,6 @@ const RELOAD_CALLBACK = new InjectionToken<() => any>("RELOAD_CALLBACK"); provide: STATE_FACTORY, useValue: new StateFactory(GlobalState, Account), }, - { - provide: CLIENT_TYPE, - useValue: ClientType.Desktop, - }, { provide: RELOAD_CALLBACK, useValue: null, @@ -94,12 +88,7 @@ const RELOAD_CALLBACK = new InjectionToken<() => any>("RELOAD_CALLBACK"); { provide: PlatformUtilsServiceAbstraction, useClass: ElectronPlatformUtilsService, - deps: [ - I18nServiceAbstraction, - MessagingServiceAbstraction, - CLIENT_TYPE, - StateServiceAbstraction, - ], + deps: [I18nServiceAbstraction, MessagingServiceAbstraction], }, { provide: I18nServiceAbstraction, diff --git a/apps/desktop/src/platform/services/electron-platform-utils.service.ts b/apps/desktop/src/platform/services/electron-platform-utils.service.ts index 485490c0a8..6f4f55b4f4 100644 --- a/apps/desktop/src/platform/services/electron-platform-utils.service.ts +++ b/apps/desktop/src/platform/services/electron-platform-utils.service.ts @@ -4,7 +4,6 @@ import { ClientType, DeviceType } from "@bitwarden/common/enums"; import { I18nService } from "@bitwarden/common/platform/abstractions/i18n.service"; import { MessagingService } from "@bitwarden/common/platform/abstractions/messaging.service"; import { PlatformUtilsService } from "@bitwarden/common/platform/abstractions/platform-utils.service"; -import { StateService } from "@bitwarden/common/platform/abstractions/state.service"; import { BiometricMessage, BiometricStorageAction } from "../../types/biometric-message"; import { isDev, isMacAppStore } from "../../utils"; @@ -12,12 +11,7 @@ import { isDev, isMacAppStore } from "../../utils"; export class ElectronPlatformUtilsService implements PlatformUtilsService { private deviceCache: DeviceType = null; - constructor( - protected i18nService: I18nService, - private messagingService: MessagingService, - private clientType: ClientType.Desktop | ClientType.DirectoryConnector, - private stateService: StateService - ) {} + constructor(protected i18nService: I18nService, private messagingService: MessagingService) {} getDevice(): DeviceType { if (!this.deviceCache) { @@ -44,7 +38,7 @@ export class ElectronPlatformUtilsService implements PlatformUtilsService { } getClientType() { - return this.clientType; + return ClientType.Desktop; } isFirefox(): boolean { diff --git a/libs/angular/src/services/injection-tokens.ts b/libs/angular/src/services/injection-tokens.ts index b87b239e16..af3350193e 100644 --- a/libs/angular/src/services/injection-tokens.ts +++ b/libs/angular/src/services/injection-tokens.ts @@ -17,7 +17,6 @@ export const LOGOUT_CALLBACK = new InjectionToken< export const LOCKED_CALLBACK = new InjectionToken<(userId?: string) => Promise>( "LOCKED_CALLBACK" ); -export const CLIENT_TYPE = new InjectionToken("CLIENT_TYPE"); export const LOCALES_DIRECTORY = new InjectionToken("LOCALES_DIRECTORY"); export const SYSTEM_LANGUAGE = new InjectionToken("SYSTEM_LANGUAGE"); export const LOG_MAC_FAILURES = new InjectionToken("LOG_MAC_FAILURES"); diff --git a/libs/common/src/enums/client-type.enum.ts b/libs/common/src/enums/client-type.enum.ts index 246769ebf2..54653f7446 100644 --- a/libs/common/src/enums/client-type.enum.ts +++ b/libs/common/src/enums/client-type.enum.ts @@ -2,7 +2,7 @@ export enum ClientType { Web = "web", Browser = "browser", Desktop = "desktop", - Mobile = "mobile", + // Mobile = "mobile", Cli = "cli", - DirectoryConnector = "connector", + // DirectoryConnector = "connector", }