| Index: third_party/WebKit/Source/devtools/front_end/profiler/ProfilesPanel.js
|
| diff --git a/third_party/WebKit/Source/devtools/front_end/profiler/ProfilesPanel.js b/third_party/WebKit/Source/devtools/front_end/profiler/ProfilesPanel.js
|
| index d30c0f9054a8fa68232cf5100f2ec63c15272683..8113259c349588ecdf1efffa640097a9751d96fe 100644
|
| --- a/third_party/WebKit/Source/devtools/front_end/profiler/ProfilesPanel.js
|
| +++ b/third_party/WebKit/Source/devtools/front_end/profiler/ProfilesPanel.js
|
| @@ -220,12 +220,9 @@ Profiler.ProfileType = class extends Common.Object {
|
| profileBeingRecordedRemoved() {
|
| }
|
|
|
| - _reset() {
|
| - var profiles = this._profiles.slice(0);
|
| - for (var i = 0; i < profiles.length; ++i)
|
| - this._disposeProfile(profiles[i]);
|
| + reset() {
|
| + this._profiles.slice(0).forEach(this._disposeProfile.bind(this));
|
| this._profiles = [];
|
| -
|
| this._nextProfileUid = 1;
|
| }
|
|
|
| @@ -598,9 +595,7 @@ Profiler.ProfilesPanel = class extends UI.PanelWithSidebar {
|
| }
|
|
|
| _reset() {
|
| - var types = Profiler.ProfileTypeRegistry.instance.profileTypes();
|
| - for (var i = 0; i < types.length; i++)
|
| - types[i]._reset();
|
| + Profiler.ProfileTypeRegistry.instance.profileTypes().forEach(type => type.reset());
|
|
|
| delete this.visibleView;
|
|
|
|
|