felixc / rexiv2

Rust library for read/write access to media-file metadata (Exif, XMP, and IPTC)
GNU General Public License v3.0
79 stars 17 forks source link

Clean up some uses of unwrap() and replace them with ? #67

Closed felixc closed 1 year ago

felixc commented 1 year ago

Should this error scenario ever come up, this should provide a better error message with details on what went wrong.

There are still some uses of unwrap() in functions that return primitives.

codecov[bot] commented 1 year ago

Codecov Report

Base: 68.59% // Head: 68.31% // Decreases project coverage by -0.28% :warning:

Coverage data is based on head (18008e5) compared to base (0db278f). Patch coverage: 62.06% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #67 +/- ## ========================================== - Coverage 68.59% 68.31% -0.28% ========================================== Files 1 1 Lines 968 950 -18 ========================================== - Hits 664 649 -15 + Misses 304 301 -3 ``` | [Impacted Files](https://codecov.io/gh/felixc/rexiv2/pull/67?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Felix+Crux) | Coverage Δ | | |---|---|---| | [src/lib.rs](https://codecov.io/gh/felixc/rexiv2/pull/67?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Felix+Crux#diff-c3JjL2xpYi5ycw==) | `68.31% <62.06%> (-0.28%)` | :arrow_down: | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Felix+Crux). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Felix+Crux)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.