mirror of
https://github.com/status-im/react-native.git
synced 2025-02-03 13:14:42 +00:00
Check before overriding global.performance
Reviewed By: gaearon Differential Revision: D5218876 fbshipit-source-id: 7fbe9ca020774a0c53d8cbb64996680112828709
This commit is contained in:
parent
2984628357
commit
9d4cc7cce4
@ -100,7 +100,9 @@ if (!global.process.env.NODE_ENV) {
|
||||
const Systrace = require('Systrace');
|
||||
Systrace.setEnabled(global.__RCTProfileIsProfiling || false);
|
||||
if (__DEV__) {
|
||||
global.performance = Systrace.getUserTimingPolyfill();
|
||||
if (global.performance === undefined) {
|
||||
global.performance = Systrace.getUserTimingPolyfill();
|
||||
}
|
||||
}
|
||||
|
||||
// Set up console
|
||||
|
Loading…
x
Reference in New Issue
Block a user