Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detect Ghostery Desktop browser #602

Merged
merged 2 commits into from Sep 21, 2020
Merged
Changes from 1 commit
Commits
File filter
Filter file types
Jump to
Jump to file
Failed to load files.

Always

Just for now

Next

Detect Ghostery Desktop browser

  • Loading branch information
sammacbeth committed Sep 14, 2020
commit 01e31ad41e365387313e2b22603a88ae72e512a8
@@ -178,6 +178,11 @@ class Globals {
this.BROWSER_INFO.displayName = 'Yandex';
this.BROWSER_INFO.name = 'yandex';
this.BROWSER_INFO.token = 'yx';
} else if (navigator.userAgent.includes('Ghostery')) {
// ua-parser library doesn't parse the desktop browser UA properly
this.BROWSER_INFO.displayName = 'Ghostery Desktop Browser';
this.BROWSER_INFO.name = 'ghostery_desktop';
this.BROWSER_INFO.token = 'gd';
}

// Set OS property
@@ -195,7 +200,9 @@ class Globals {
this.BROWSER_INFO.version = version;

// Check for the Ghostery Android browser
this._checkForGhosteryAndroid();
if (platform.includes('android')) {
this._checkForGhosteryAndroid();
}
}

/**
ProTip! Use n and p to navigate between commits in a pull request.