Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Editorial: Use more precise exceptions #417

Merged
merged 3 commits into from
Jun 20, 2023
Merged

Conversation

a-sully
Copy link
Collaborator

@a-sully a-sully commented Jun 15, 2023

Before: throw a {{SecurityError}}
After: [=throw=] a "{{SecurityError}}" {{DOMException}}

See whatwg/fs#63 and whatwg/fs#89. Fixed in the upstream spec in whatwg/fs#70 and whatwg/fs#91, respectively


Preview | Diff

@a-sully a-sully requested a review from inexorabletash June 15, 2023 22:20
index.bs Outdated
@@ -322,7 +325,7 @@ should be treated by the user agent as the user intending to grant read access t
for the returned files. As such, at the time the promise returned by one of the [=local file system handle factories=]
resolves, [=permission state=] for a descriptor with {{FileSystemPermissionDescriptor/handle}} set to the returned handle,
and {{FileSystemPermissionDescriptor/mode}} set to {{"read"}}
should be {{PermissionState/"granted"}}.
should be {{PermissionState/granted}}.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We still want quotes, just around the whole thing i.e. "{{PermissionState/granted}}"

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apologies, I was considering making this change (to address whatwg/fs#133) in this PR and then decided to leave it for a follow-up... but incorrectly undo-ed my changes 🤦

I'll send a follow-up with these changes

index.bs Outdated Show resolved Hide resolved
index.bs Outdated Show resolved Hide resolved
Copy link
Member

@inexorabletash inexorabletash left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one nit, otherwise LG

index.bs Outdated Show resolved Hide resolved
index.bs Outdated Show resolved Hide resolved
@a-sully a-sully merged commit a350a87 into WICG:main Jun 20, 2023
@a-sully a-sully deleted the better-exceptions branch June 20, 2023 21:26
github-actions bot added a commit that referenced this pull request Jun 20, 2023
Before: `throw a {{SecurityError}}`
After: `[=throw=] a "{{SecurityError}}" {{DOMException}}`

See whatwg/fs#63 and whatwg/fs#89. Fixed in the upstream spec in whatwg/fs#70 and whatwg/fs#91, respectively

SHA: a350a87
Reason: push, by @a-sully

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
a-sully added a commit that referenced this pull request Jun 20, 2023
Before: `{{PermissionState/"granted"}}`
After: `"{{PermissionState/granted}}"`

See whatwg/fs#133. Also called out here: #417 (comment)
github-actions bot added a commit that referenced this pull request Jun 20, 2023
Before: `{{PermissionState/"granted"}}`
After: `"{{PermissionState/granted}}"`

See whatwg/fs#133. Also called out here: #417 (comment)

SHA: 44df0c4
Reason: push, by @a-sully

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants