mirror of
https://github.com/chatmail/core.git
synced 2026-05-22 16:26:31 +03:00
Rename Param::MessageId into Param::MsgId
MsgId refers to database ID, same as crate::message::MsgId newtype.
This commit is contained in:
@@ -1079,7 +1079,7 @@ fn suspend_smtp_thread(context: &Context, suspend: bool) {
|
|||||||
|
|
||||||
fn send_mdn(context: &Context, msg: &Message) -> Result<()> {
|
fn send_mdn(context: &Context, msg: &Message) -> Result<()> {
|
||||||
let mut param = Params::new();
|
let mut param = Params::new();
|
||||||
param.set(Param::MessageId, msg.id.to_u32().to_string());
|
param.set(Param::MsgId, msg.id.to_u32().to_string());
|
||||||
|
|
||||||
job_add(context, Action::SendMdn, msg.from_id as i32, param, 0);
|
job_add(context, Action::SendMdn, msg.from_id as i32, param, 0);
|
||||||
|
|
||||||
|
|||||||
@@ -119,7 +119,7 @@ pub enum Param {
|
|||||||
GroupName = b'g',
|
GroupName = b'g',
|
||||||
|
|
||||||
/// For MDN-sending job
|
/// For MDN-sending job
|
||||||
MessageId = b'I',
|
MsgId = b'I',
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Possible values for `Param::ForcePlaintext`.
|
/// Possible values for `Param::ForcePlaintext`.
|
||||||
@@ -317,7 +317,7 @@ impl Params {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub fn get_msg_id(&self) -> Option<MsgId> {
|
pub fn get_msg_id(&self) -> Option<MsgId> {
|
||||||
self.get(Param::MessageId)
|
self.get(Param::MsgId)
|
||||||
.and_then(|x| x.parse::<u32>().ok())
|
.and_then(|x| x.parse::<u32>().ok())
|
||||||
.map(MsgId::new)
|
.map(MsgId::new)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user