diff --git a/index.bs b/index.bs index c07a1dd6..183a18d4 100644 --- a/index.bs +++ b/index.bs @@ -11333,12 +11333,6 @@ WebExtensionsResult = ( #### The extensions.Extension Type #### {#type-webExtensions-Extension} -
-webExtensions.ExtensionArchive = {
-   files: [+text],
-}
-
-
To expand a extension data spec given |extension data spec|: @@ -11350,26 +11344,24 @@ To expand a extension data spec given |extension data spec|:
"path" -
Let |path| be a value of path field of |extension data spec|. +
+ 1. Let |path| be a value of path field of |extension data spec|. + 1. Let |entry| be a [=directory entry=] represeting the directory with that |path|.
"archive-path"
1. Let |archive path| be a value of path field of |extension data spec|. - 1. Perform any implementation-defined steps to extract ZIP from |archive path|, if this fails return [=error=] with [=error code=] [=invalid web-extension=]. + 1. Perform any implementation-defined steps to extract ZIP from |archive path| and let |entry| by a [=directory entry=] representing the extraction result, if this fails return [=error=] with [=error code=] [=invalid web-extension=].
"base64"
1. Let |archive path| be a value of path field of |extension data spec|. 1. Let |bytes| be [=for giving-base64 decode=] |extension data spec|["path"]. - 1. Perform any implementation-defined steps to extract ZIP from |bytes|, if this fails return [=error=] with [=error code=] [=invalid web-extension=]. + 1. Perform any implementation-defined steps to extract ZIP from |bytes| and let |entry| by a [=directory entry=] representing the extraction result, if this fails return [=error=] with [=error code=] [=invalid web-extension=].
-1. Let |extension files| be a result of implementation-defined steps to list all paths in |path| folder. - -1. Let |extension archive| be a map matching the webExtensions.ExtensionArchive production, with the files field set to |extension files|. - -1. Return [=success=] with data |extension archive|. +1. Return [=success=] with data |entry|.
@@ -11426,13 +11418,11 @@ The [=remote end steps=] with |session| and |command parameters| are: 1. Let |extension data spec| be a value of extensionData field of the |command parameters|. -1. Let |extension archive| be the result of [=trying=] to [=expand a extension data spec=] with |extension data spec|. - -1. Let |extension files| be a value of files field of |extension archive|. +1. Let |extension directory entry| be the result of [=trying=] to [=expand a extension data spec=] with |extension data spec|. -1. If |extension files| does not include entry manifest.json return [=error=] with [=error code=] [=invalid web-extension=]. +1. If |extension directory entry| does not include file manifest.json return [=error=] with [=error code=] [=invalid web-extension=]. -1. Perform implementation defined steps to install |extension archive|. If this fails, return [=error=] with [=error code=] [=invalid extension=]. Otherwise let |extension id| be the unique identifier of the newly installed extension. +1. Perform implementation defined steps to install |extension directory entry|. If this fails, return [=error=] with [=error code=] [=invalid extension=]. Otherwise let |extension id| be the unique identifier of the newly installed extension. 1. Let |allow private browsing| be a value of allowPrivateBrowsing field of |command parameters| if present, or false otherwise.