mirror of
https://github.com/bitwarden/browser
synced 2026-02-10 13:40:06 +00:00
[PM-19814] Add phishing detection feature flag.
This commit is contained in:
@@ -1310,12 +1310,23 @@ export default class MainBackground {
|
||||
|
||||
this.inlineMenuFieldQualificationService = new InlineMenuFieldQualificationService();
|
||||
|
||||
PhishingDetectionService.initialize(
|
||||
this.auditService,
|
||||
this.logService,
|
||||
this.storageService,
|
||||
this.taskSchedulerService,
|
||||
);
|
||||
this.configService
|
||||
.getFeatureFlag(FeatureFlag.PhishingDetection)
|
||||
.then((enabled) => {
|
||||
if (enabled) {
|
||||
PhishingDetectionService.initialize(
|
||||
this.auditService,
|
||||
this.logService,
|
||||
this.storageService,
|
||||
this.taskSchedulerService,
|
||||
);
|
||||
} else {
|
||||
this.logService.info("phishing detection feature flag is disabled.");
|
||||
}
|
||||
})
|
||||
.catch((error) =>
|
||||
this.logService.error("Failed to check phishing detection feature flag", error),
|
||||
);
|
||||
}
|
||||
|
||||
async bootstrap() {
|
||||
|
||||
@@ -54,6 +54,8 @@ export class PhishingDetectionService {
|
||||
|
||||
// Set up periodic updates every 24 hours
|
||||
this.setupPeriodicUpdates();
|
||||
|
||||
PhishingDetectionService.logService.info("Phishing detection feature is initialized.");
|
||||
}
|
||||
|
||||
private static setupPeriodicUpdates() {
|
||||
|
||||
Reference in New Issue
Block a user