mirror of
https://github.com/chatmail/core.git
synced 2026-05-19 23:06:32 +03:00
feat(ffi): Warning instead of error if dc_get_msg() could not retrieve message
As trashed messages can't be loaded from the db now by `Message::load_from_db()` returning an error for such messages, errors from `Message::load_from_db()` should be logged as warnings. If it's really an error like a db failure, it should be logged internally.
This commit is contained in:
@@ -2008,7 +2008,7 @@ pub unsafe extern "C" fn dc_get_msg(context: *mut dc_context_t, msg_id: u32) ->
|
|||||||
);
|
);
|
||||||
message::Message::default()
|
message::Message::default()
|
||||||
} else {
|
} else {
|
||||||
error!(ctx, "dc_get_msg could not retrieve msg_id {msg_id}: {e:#}");
|
warn!(ctx, "dc_get_msg could not retrieve msg_id {msg_id}: {e:#}");
|
||||||
return ptr::null_mut();
|
return ptr::null_mut();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user