Expand description
§Bitwarden UniFFI error
This crate provides some utilities to convert results inside uniffi::custom_type!
calls, so that
they don’t produce panics when there is a parsing error.
Structs§
- Error
- The
Error
type, a wrapper around a dynamic error type.
Statics§
Functions§
- convert_
error 🔒 - convert_
result - Convert a
Result
into one that will not cause a panic when called inside [uniffi::custom_type!
]. It is required that all the results created inside acustom_type!
are converted using this function. - set_
error_ to_ uniffi_ error - Configure an error converter to convert errors in calls to [
uniffi::custom_type!
] into the main error of the application (bitwarden_uniffi::error::BitwardenError). This is needed because if the errors don't match, Uniffi will panic instead of returning an error. This needs to be called by the
bitwarden_uniffi` crate before any other Uniffi code is run.