Skip to content

Commit 371f73a

Browse files
committed
Don't try anything Intercom related if preference not enabled (#1354)
1 parent 2a607af commit 371f73a

File tree

1 file changed

+4
-2
lines changed
  • src/internal-plugins/metrics/lib

1 file changed

+4
-2
lines changed

src/internal-plugins/metrics/lib/setup.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ module.exports = function() {
3737
}
3838
});
3939

40-
if (process.env.HADRON_PRODUCT !== 'mongodb-compass-community') {
40+
if (process.env.HADRON_PRODUCT !== 'mongodb-compass-community' && app.preferences.enableFeedbackPanel) {
4141
const request = new XMLHttpRequest();
4242
request.onreadystatechange = () => {
4343
try {
@@ -163,7 +163,9 @@ module.exports = function() {
163163
* such that when a link is clicked, the event is properly
164164
* passed off to `app.router` and a web page actually opens.
165165
*/
166-
if (process.env.HADRON_PRODUCT !== 'mongodb-compass-community' && !intercomBlocked) {
166+
if (process.env.HADRON_PRODUCT !== 'mongodb-compass-community' &&
167+
!intercomBlocked &&
168+
app.preferences.enableFeedbackPanel) {
167169
intercom.configure();
168170
}
169171

0 commit comments

Comments
 (0)