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

Do not jump to first file when using FSA API #1268

Merged

Conversation

Jaifroid
Copy link
Member

Fixes #1254.

This should be the last of the issue-fixing PRs prior to preparing release of v4.1.

It ensures that a ZIM file is not actually opened if the user selected a directory of archives using the File System Access window.showDirectoryPicker() method, and if that folder contains more than one archive. Without this fix, the first archive in the directory is inadvertently opened, which is unexpected and potentially insecure behaviour.

I need to test whether the same applies to the webkitdirectory method used by Firefox and Edge Legacy.

@Jaifroid Jaifroid added regression Broken things that used to work backend user interface bug-non-critical For bugs that it would be nice to fix rather than critical to fix labels Jul 11, 2024
@Jaifroid Jaifroid added this to the v4.1 milestone Jul 11, 2024
@Jaifroid Jaifroid self-assigned this Jul 11, 2024
@Jaifroid Jaifroid marked this pull request as draft July 11, 2024 14:21
@Jaifroid
Copy link
Member Author

Also works as intended with webkitdirectory method.

@Jaifroid Jaifroid marked this pull request as ready for review July 11, 2024 14:32
@Jaifroid Jaifroid requested a review from audiodude July 11, 2024 14:32
@Jaifroid
Copy link
Member Author

Ah, I forgot, I also need to do #1257 as we had agreed. So there will be one more issue-fixing PR after this.

Copy link
Collaborator

@audiodude audiodude left a comment

Choose a reason for hiding this comment

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

LGTM

@Jaifroid Jaifroid merged commit 4ce5d47 into main Jul 12, 2024
9 checks passed
@Jaifroid Jaifroid deleted the Do-not-jump-to-first-file-when-using-showDirectoryPicker branch July 12, 2024 07:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend bug-non-critical For bugs that it would be nice to fix rather than critical to fix regression Broken things that used to work user interface
Projects
None yet
Development

Successfully merging this pull request may close these issues.

When opening a folder of archives with FSA API, do not jump straight to the first file
2 participants