Open Bug 1649622 Opened 4 years ago Updated 4 years ago

Remove duplicated calls to listFrames/initPerformance in Toolbox codebase

Categories

(DevTools :: Framework, enhancement)

enhancement

Tracking

(Not tracked)

People

(Reporter: ochameau, Unassigned)

References

(Blocks 1 open bug)

Details

We currently do call:

      await this._listFrames();
      await this.initPerformance();

From two callsites (open and switchToTarget):
https://searchfox.org/mozilla-central/rev/5a4aaccb28665807a6fd49cf48367d47fbb5a19a/devtools/client/framework/toolbox.js#571-573
https://searchfox.org/mozilla-central/rev/5a4aaccb28665807a6fd49cf48367d47fbb5a19a/devtools/client/framework/toolbox.js#864
https://searchfox.org/mozilla-central/rev/5a4aaccb28665807a6fd49cf48367d47fbb5a19a/devtools/client/framework/toolbox.js#979-981
Bug 1646459 is going to move switchToTarget calls to onTargetAvailable.
But still, we potentially call these method twice and should probably only keep the calls from onTargetAvailable.

You need to log in before you can comment on or make changes to this bug.