mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-19 16:25:38 +00:00
Bug 1525966 - Support string errors when detach fails in target fronts r=nchevobbe
Depends on D55829 In case other rejects are still using strings instead of error objects. Differential Revision: https://phabricator.services.mozilla.com/D55830 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
5bc4238d39
commit
5fb20254ae
@ -138,7 +138,8 @@ class BrowsingContextTargetFront extends TargetMixin(
|
||||
response = await super.detach();
|
||||
} catch (e) {
|
||||
console.warn(
|
||||
`Error while detaching the browsing context target front: ${e.message}`
|
||||
"Error while detaching the browsing context target front:",
|
||||
e
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -454,7 +454,7 @@ function TargetMixin(parentClass) {
|
||||
} catch (e) {
|
||||
// Ignore any errors while closing, since there is not much that can be done
|
||||
// at this point.
|
||||
console.warn(`Error while closing client: ${e.message}`);
|
||||
console.warn("Error while closing client:", e);
|
||||
}
|
||||
|
||||
// Not all targets supports attach/detach. For example content process doesn't.
|
||||
@ -467,7 +467,7 @@ function TargetMixin(parentClass) {
|
||||
try {
|
||||
await this.detach();
|
||||
} catch (e) {
|
||||
console.warn(`Error while detaching target: ${e.message}`);
|
||||
console.warn("Error while detaching target:", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -92,9 +92,7 @@ class WorkerTargetFront extends TargetMixin(
|
||||
try {
|
||||
response = await super.detach();
|
||||
} catch (e) {
|
||||
console.warn(
|
||||
`Error while detaching the worker target front: ${e.message}`
|
||||
);
|
||||
console.warn("Error while detaching the worker target front:", e);
|
||||
}
|
||||
|
||||
if (this.registration) {
|
||||
|
Loading…
Reference in New Issue
Block a user