Created
January 7, 2021 21:49
-
-
Save jasonLaster/a76796b2005f2242a565685bd7b61121 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/devtools/client/webconsole/components/Output/Message.js b/src/devtools/client/webconsole/components/Output/Message.js | |
index d7b51742..66199aa7 100644 | |
--- a/src/devtools/client/webconsole/components/Output/Message.js | |
+++ b/src/devtools/client/webconsole/components/Output/Message.js | |
@@ -11,7 +11,6 @@ const { actions } = require("ui/actions/index"); | |
const { MESSAGE_TYPE } = require("devtools/client/webconsole/constants"); | |
const { MessageIndent } = require("devtools/client/webconsole/components/Output/MessageIndent"); | |
const MessageIcon = require("devtools/client/webconsole/components/Output/MessageIcon"); | |
-const { CloseButton } = require("devtools/client/debugger/src/components/shared/Button"); | |
const FrameView = createFactory(require("devtools/client/shared/components/Frame")); | |
const CollapseButton = require("devtools/client/webconsole/components/Output/CollapseButton"); | |
@@ -19,6 +18,10 @@ const MessageRepeat = require("devtools/client/webconsole/components/Output/Mess | |
const PropTypes = require("prop-types"); | |
const SmartTrace = require("devtools/client/shared/components/SmartTrace"); | |
+function toBigInt(num) { | |
+ return num ? BigInt(num) : undefined; | |
+} | |
+ | |
class Message extends Component { | |
static get propTypes() { | |
return { | |
@@ -148,7 +151,7 @@ class Message extends Component { | |
isFirstMessageForPoint, | |
} = this.props; | |
- if (inWarningGroup || !pausedExecutionPoint || !executionPoint || !frame) { | |
+ if (inWarningGroup || !executionPoint || !frame) { | |
return undefined; | |
} | |
@@ -161,11 +164,11 @@ class Message extends Component { | |
this.onViewSourceInDebugger({ ...frame, url: frame.source }); | |
}; | |
- if (BigInt(executionPoint) > BigInt(pausedExecutionPoint)) { | |
+ if (toBigInt(executionPoint) > toBigInt(pausedExecutionPoint)) { | |
overlayType = "fast-forward"; | |
label = "Fast Forward"; | |
onClick = onRewindClick; | |
- } else if (BigInt(executionPoint) < BigInt(pausedExecutionPoint)) { | |
+ } else if (toBigInt(executionPoint) < toBigInt(pausedExecutionPoint)) { | |
overlayType = "rewind"; | |
label = "Rewind"; | |
onClick = onRewindClick; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment