Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions packages/rs-platform-wallet-ffi/src/persistence.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1430,10 +1430,10 @@ impl PlatformWalletPersistence for FFIPersister {
.on_load_shielded_outgoing_notes_free_fn
.is_some()
{
return Err("on_load_shielded_outgoing_notes_fn and \
on_load_shielded_outgoing_notes_free_fn must be provided together"
.to_string()
.into());
return Err(PersistenceError::backend(
"on_load_shielded_outgoing_notes_fn and \
on_load_shielded_outgoing_notes_free_fn must be provided together",
));
}

// 1) notes
Expand Down Expand Up @@ -1508,11 +1508,10 @@ impl PlatformWalletPersistence for FFIPersister {
let rc =
unsafe { load_outgoing(self.callbacks.context, &mut out_ptr, &mut out_count) };
if rc != 0 {
return Err(format!(
return Err(PersistenceError::backend(format!(
"on_load_shielded_outgoing_notes_fn returned error code {}",
rc
)
.into());
)));
}
struct OutgoingGuard {
context: *mut c_void,
Expand Down
Loading