Skip to content

Comments

fix: validate URI scheme and improve error messages#22

Merged
lodev09 merged 1 commit intomainfrom
fix/uri-scheme-validation
Feb 8, 2026
Merged

fix: validate URI scheme and improve error messages#22
lodev09 merged 1 commit intomainfrom
fix/uri-scheme-validation

Conversation

@lodev09
Copy link
Owner

@lodev09 lodev09 commented Feb 8, 2026

Summary

Reject bare file paths (e.g. /var/mobile/...) with a clear error message indicating that a scheme (file://, ph://, content://) is required.

  • iOS: add scheme validation in read and write methods
  • Android: add scheme validation in write, improve read error message
  • Add JSDoc to read() and write()
  • Update README with URI format note

Closes #9

Type of Change

  • Bug fix
  • Documentation update

Test Plan

Pass a bare file path (e.g. /var/mobile/.../image.jpg) to read() and write() — should reject with a descriptive error.

Checklist

  • I tested on iOS
  • I tested on Android
  • I updated the documentation (if needed)

Reject bare file paths (e.g. /var/mobile/...) with a clear error message
indicating that a scheme (file://, ph://, content://) is required.

- iOS: add scheme validation in read and write methods
- Android: add scheme validation in write, improve read error message
- Add JSDoc to read() and write()
- Update README with URI format note

Closes #9
@lodev09 lodev09 merged commit 77afa09 into main Feb 8, 2026
3 checks passed
@lodev09 lodev09 deleted the fix/uri-scheme-validation branch February 8, 2026 23:16
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.

Can’t read EXIF data from a file in a private path

1 participant