From 2c8eef6d8901be84f41093a6f6758362cb413696 Mon Sep 17 00:00:00 2001 From: Simon Pieters Date: Tue, 22 Nov 2016 13:37:45 +0100 Subject: [PATCH] Invoke the URL serializer for ErrorEvent.filename The URL's hash should be included to match majority of browser engines (WebKit, Gecko, Edge). An "absolute URL" is without the hash according to the URL standard, but serializing a URL record includes it by default. Fixes #2074. Closes w3c/web-platform-tests#4221. --- source | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/source b/source index 561947ecb83..7c4f6bb8933 100644 --- a/source +++ b/source @@ -88020,8 +88020,9 @@ document.querySelector("button").addEventListener("click", bound);
  • -

    Let location be an absolute URL that corresponds to the - resource from which script was obtained.

    +

    Let urlString be the result of applying the URL serializer to the URL record that + corresponds to the resource from which script was obtained.

    The resource containing the script will typically be the file from which the Document was parsed, e.g. for inline script elements or event @@ -88043,7 +88044,7 @@ document.querySelector("button").addEventListener("click", bound);

  • If script has muted errors, then set message to "Script error.", location to the empty string, line and + data-x="">Script error.", urlString to the empty string, line and col to 0, and errorValue to null.

  • Let notHandled be the result of firing an @@ -88051,7 +88052,7 @@ document.querySelector("button").addEventListener("click", bound); ErrorEvent, with the cancelable attribute initialized to true, the message attribute initialized to message, the filename - attribute initialized to location, the urlString, the lineno attribute initialized to line, the colno attribute initialized to col, and the error attribute initialized to @@ -88108,8 +88109,8 @@ dictionary ErrorEventInit : EventInit { value it was initialized to. It represents the error message.

    The filename attribute must return the - value it was initialized to. It represents the absolute URL of the script in which - the error originally occurred.

    + value it was initialized to. It represents the URL of the script in which the error + originally occurred.

    The lineno attribute must return the value it was initialized to. It represents the line number where the error occurred in the