diff options
Diffstat (limited to 'toolkit/components/satchel/FormHistoryChild.sys.mjs')
-rw-r--r-- | toolkit/components/satchel/FormHistoryChild.sys.mjs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/toolkit/components/satchel/FormHistoryChild.sys.mjs b/toolkit/components/satchel/FormHistoryChild.sys.mjs index 242d8f2e29..e97b5238e8 100644 --- a/toolkit/components/satchel/FormHistoryChild.sys.mjs +++ b/toolkit/components/satchel/FormHistoryChild.sys.mjs @@ -35,15 +35,16 @@ function log(message) { export class FormHistoryChild extends JSWindowActorChild { handleEvent(event) { switch (event.type) { - case "DOMFormBeforeSubmit": - this.#onDOMFormBeforeSubmit(event.target); + case "form-submission-detected": + this.#onFormSubmission(event); break; default: throw new Error("Unexpected event"); } } - #onDOMFormBeforeSubmit(form) { + #onFormSubmission(event) { + const form = event.detail.form; if ( !lazy.gEnabled || lazy.PrivateBrowsingUtils.isContentWindowPrivate(form.ownerGlobal) |