Skip to content

Commit 465f8c2

Browse files
committed
chore: no health popup in windows/mac desktop as its managed by the installer
1 parent 3314f2f commit 465f8c2

1 file changed

Lines changed: 13 additions & 9 deletions

File tree

src/extensions/default/HealthData/HealthDataNotification.js

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,19 @@ define(function (require, exports, module) {
2121
}
2222

2323
function _showFirstLaunchPopup() {
24-
if(!window.testEnvironment){
25-
const alreadyShown = PreferencesManager.getViewState("healthDataNotificationShown");
26-
const prefs = PreferencesManager.getExtensionPrefs("healthData");
27-
if (!alreadyShown && prefs.get("healthDataTracking")) {
28-
HealthDataPopup.showFirstLaunchTooltip()
29-
.done(function () {
30-
PreferencesManager.setViewState("healthDataNotificationShown", true);
31-
});
32-
}
24+
const agreementManagedByInstaller = Phoenix.isNativeApp &&
25+
(brackets.platform === "mac" || brackets.platform === "win");
26+
if(window.testEnvironment || agreementManagedByInstaller){
27+
return;
28+
}
29+
30+
const alreadyShown = PreferencesManager.getViewState("healthDataNotificationShown");
31+
const prefs = PreferencesManager.getExtensionPrefs("healthData");
32+
if (!alreadyShown && prefs.get("healthDataTracking")) {
33+
HealthDataPopup.showFirstLaunchTooltip()
34+
.done(function () {
35+
PreferencesManager.setViewState("healthDataNotificationShown", true);
36+
});
3337
}
3438
}
3539

0 commit comments

Comments
 (0)