mirror of
https://github.com/bitwarden/browser
synced 2025-12-17 00:33:44 +00:00
Remove last remnants of old analytics code (#345)
This commit is contained in:
@@ -16,14 +16,12 @@ import { MessagingService } from '../../abstractions/messaging.service';
|
||||
import { PlatformUtilsService } from '../../abstractions/platformUtils.service';
|
||||
import { StorageService } from '../../abstractions/storage.service';
|
||||
|
||||
import { AnalyticsIds } from '../../misc/analytics';
|
||||
import { ElectronConstants } from '../electronConstants';
|
||||
|
||||
export class ElectronPlatformUtilsService implements PlatformUtilsService {
|
||||
identityClientId: string;
|
||||
|
||||
private deviceCache: DeviceType = null;
|
||||
private analyticsIdCache: string = null;
|
||||
|
||||
constructor(private i18nService: I18nService, private messagingService: MessagingService,
|
||||
private isDesktopApp: boolean, private storageService: StorageService) {
|
||||
@@ -86,19 +84,6 @@ export class ElectronPlatformUtilsService implements PlatformUtilsService {
|
||||
return isMacAppStore();
|
||||
}
|
||||
|
||||
analyticsId(): string {
|
||||
if (!this.isDesktopApp) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (this.analyticsIdCache) {
|
||||
return this.analyticsIdCache;
|
||||
}
|
||||
|
||||
this.analyticsIdCache = (AnalyticsIds as any)[this.getDevice()];
|
||||
return this.analyticsIdCache;
|
||||
}
|
||||
|
||||
isViewOpen(): Promise<boolean> {
|
||||
return Promise.resolve(false);
|
||||
}
|
||||
@@ -163,14 +148,6 @@ export class ElectronPlatformUtilsService implements PlatformUtilsService {
|
||||
return Promise.resolve(result.response === 0);
|
||||
}
|
||||
|
||||
eventTrack(action: string, label?: string, options?: any) {
|
||||
this.messagingService.send('analyticsEventTrack', {
|
||||
action: action,
|
||||
label: label,
|
||||
options: options,
|
||||
});
|
||||
}
|
||||
|
||||
isDev(): boolean {
|
||||
return isDev();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user