Skip to content

Commit d61f709

Browse files
committed
Remove dead code as facebook.github.io/react always redirects to reactjs.org, which has prod version of react. so removing this check
1 parent c6d64f1 commit d61f709

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

packages/react-devtools-extensions/src/background.js

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -98,18 +98,7 @@ chrome.runtime.onMessage.addListener((request, sender) => {
9898
// We use browserAction instead of pageAction because this lets us
9999
// display a custom default popup when React is *not* detected.
100100
// It is specified in the manifest.
101-
let reactBuildType = request.reactBuildType;
102-
if (sender.url.indexOf('reactjs.org') !== -1) {
103-
// Cheat: We use the development version on the website because
104-
// it is better for interactive examples. However we're going
105-
// to get misguided bug reports if the extension highlights it
106-
// as using the dev version. We're just going to special case
107-
// our own documentation and cheat. It is acceptable to use dev
108-
// version of React in React docs, but not in any other case.
109-
reactBuildType = 'production';
110-
}
111-
112-
setIconAndPopup(reactBuildType, sender.tab.id);
101+
setIconAndPopup(request.reactBuildType, sender.tab.id);
113102
}
114103
}
115104
});

0 commit comments

Comments
 (0)