diff --git a/deltachat-ffi/deltachat.h b/deltachat-ffi/deltachat.h index 755febcef..6e4a824d4 100644 --- a/deltachat-ffi/deltachat.h +++ b/deltachat-ffi/deltachat.h @@ -4973,17 +4973,6 @@ uint32_t dc_msg_get_original_msg_id (const dc_msg_t* msg); */ uint32_t dc_msg_get_saved_msg_id (const dc_msg_t* msg); - -/** - * Force the message to be sent in plain text. - * - * This API is for bots, there is no need to expose it in the UI. - * - * @memberof dc_msg_t - * @param msg The message object. - */ -void dc_msg_force_plaintext (dc_msg_t* msg); - /** * @class dc_contact_t * diff --git a/deltachat-ffi/src/lib.rs b/deltachat-ffi/src/lib.rs index 7f319e669..4aa889d27 100644 --- a/deltachat-ffi/src/lib.rs +++ b/deltachat-ffi/src/lib.rs @@ -4054,16 +4054,6 @@ pub unsafe extern "C" fn dc_msg_get_saved_msg_id(msg: *const dc_msg_t) -> u32 { }) } -#[no_mangle] -pub unsafe extern "C" fn dc_msg_force_plaintext(msg: *mut dc_msg_t) { - if msg.is_null() { - eprintln!("ignoring careless call to dc_msg_force_plaintext()"); - return; - } - let ffi_msg = &mut *msg; - ffi_msg.message.force_plaintext(); -} - // dc_contact_t /// FFI struct for [dc_contact_t] diff --git a/python/src/deltachat/message.py b/python/src/deltachat/message.py index 6e6d56ba5..6734c6edb 100644 --- a/python/src/deltachat/message.py +++ b/python/src/deltachat/message.py @@ -254,10 +254,6 @@ class Message: """Quote setter.""" lib.dc_msg_set_quote(self._dc_msg, quoted_message._dc_msg) - def force_plaintext(self) -> None: - """Force the message to be sent in plain text.""" - lib.dc_msg_force_plaintext(self._dc_msg) - @property def error(self) -> Optional[str]: """Error message.""" diff --git a/src/message.rs b/src/message.rs index 440ac4bcd..0ae7591cc 100644 --- a/src/message.rs +++ b/src/message.rs @@ -1319,7 +1319,7 @@ impl Message { } /// Force the message to be sent in plain text. - pub fn force_plaintext(&mut self) { + pub(crate) fn force_plaintext(&mut self) { self.param.set_int(Param::ForcePlaintext, 1); }