зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1680218 - [devtools] Remove mentions of WorkerDescriptorActor#connect. r=ochameau,devtools-backward-compat-reviewers.
The function doesn't exist anymore on newer server, so we can remove it from the spec file. Differential Revision: https://phabricator.services.mozilla.com/D98496
This commit is contained in:
Родитель
a2b70b69db
Коммит
b52e8b6f00
|
@ -88,19 +88,12 @@ class WorkerDescriptorFront extends TargetMixin(
|
|||
return;
|
||||
}
|
||||
|
||||
// Immediately retrieve console and thread actors that will be later used by Target.
|
||||
let connectResponse;
|
||||
if (this.actorID.includes("workerDescriptor")) {
|
||||
connectResponse = await super.getTarget();
|
||||
} else {
|
||||
// @backward-compat { version 83 } Older servers don't support worker descriptors.
|
||||
connectResponse = await this.connect({});
|
||||
}
|
||||
const workerTargetForm = await super.getTarget();
|
||||
|
||||
// Set the console actor ID on the form to expose it to Target.attachConsole
|
||||
// Set the ThreadActor on the target form so it is accessible by getFront
|
||||
this.targetForm.consoleActor = connectResponse.consoleActor;
|
||||
this.targetForm.threadActor = connectResponse.threadActor;
|
||||
this.targetForm.consoleActor = workerTargetForm.consoleActor;
|
||||
this.targetForm.threadActor = workerTargetForm.threadActor;
|
||||
|
||||
if (this.isDestroyedOrBeingDestroyed()) {
|
||||
return;
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
"use strict";
|
||||
|
||||
const { Arg, RetVal, generateActorSpec } = require("devtools/shared/protocol");
|
||||
const { RetVal, generateActorSpec } = require("devtools/shared/protocol");
|
||||
|
||||
const workerDescriptorSpec = generateActorSpec({
|
||||
typeName: "workerDescriptor",
|
||||
|
@ -17,13 +17,6 @@ const workerDescriptorSpec = generateActorSpec({
|
|||
request: {},
|
||||
response: RetVal("json"),
|
||||
},
|
||||
// @backward-compat { version 83 } We don't use `connect` anymore.
|
||||
connect: {
|
||||
request: {
|
||||
options: Arg(0, "json"),
|
||||
},
|
||||
response: RetVal("json"),
|
||||
},
|
||||
getTarget: {
|
||||
request: {},
|
||||
response: RetVal("json"),
|
||||
|
|
Загрузка…
Ссылка в новой задаче