Skip to content

Commit

Permalink
Undo changes from jonhoo#242.
Browse files Browse the repository at this point in the history
  • Loading branch information
pythonspeed committed Sep 27, 2022
1 parent 900f255 commit 14ae2a3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/flamegraph/flamegraph.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ function init(evt) {
svg.removeAttribute("width");
// Edge requires us to have a viewBox that gets updated with size changes.
var isEdge = /Edge\/\d./i.test(navigator.userAgent);
if (!isEdge) {
svg.removeAttribute("viewBox");
}
var update_for_width_change = function() {
if (isEdge) {
svg.attributes.viewBox.value = "0 0 " + svg.width.baseVal.value + " " + svg.height.baseVal.value;
Expand Down Expand Up @@ -51,9 +54,6 @@ function init(evt) {
unzoom();
update_for_width_change();
restore_state();
if (!isEdge) {
svg.removeAttribute("viewBox");
}
}, 0);
} else {
restore_state();
Expand Down

0 comments on commit 14ae2a3

Please sign in to comment.