mirror of
https://github.com/chatmail/core.git
synced 2026-05-13 03:46:32 +03:00
Remove default signature advertsing Delta Chat
This commit is contained in:
@@ -5634,12 +5634,6 @@ void dc_event_unref(dc_event_t* event);
|
|||||||
/// Used in summaries.
|
/// Used in summaries.
|
||||||
#define DC_STR_FILE 12
|
#define DC_STR_FILE 12
|
||||||
|
|
||||||
/// "Sent with my Delta Chat Messenger: https://delta.chat"
|
|
||||||
///
|
|
||||||
/// Used as the default footer
|
|
||||||
/// if nothing else is set by the dc_set_config()-option `selfstatus`.
|
|
||||||
#define DC_STR_STATUSLINE 13
|
|
||||||
|
|
||||||
/// "Group name changed from %1$s to %2$s."
|
/// "Group name changed from %1$s to %2$s."
|
||||||
///
|
///
|
||||||
/// Used in status messages for group name changes.
|
/// Used in status messages for group name changes.
|
||||||
|
|||||||
@@ -13,7 +13,6 @@ use crate::events::EventType;
|
|||||||
use crate::message::MsgId;
|
use crate::message::MsgId;
|
||||||
use crate::mimefactory::RECOMMENDED_FILE_SIZE;
|
use crate::mimefactory::RECOMMENDED_FILE_SIZE;
|
||||||
use crate::provider::{get_provider_by_id, Provider};
|
use crate::provider::{get_provider_by_id, Provider};
|
||||||
use crate::stock_str;
|
|
||||||
|
|
||||||
/// The available configuration keys.
|
/// The available configuration keys.
|
||||||
#[derive(
|
#[derive(
|
||||||
@@ -199,7 +198,6 @@ impl Context {
|
|||||||
|
|
||||||
// Default values
|
// Default values
|
||||||
match key {
|
match key {
|
||||||
Config::Selfstatus => Ok(Some(stock_str::status_line(self).await)),
|
|
||||||
Config::ConfiguredInboxFolder => Ok(Some("INBOX".to_owned())),
|
Config::ConfiguredInboxFolder => Ok(Some("INBOX".to_owned())),
|
||||||
_ => Ok(key.get_str("default").map(|s| s.to_string())),
|
_ => Ok(key.get_str("default").map(|s| s.to_string())),
|
||||||
}
|
}
|
||||||
@@ -285,17 +283,6 @@ impl Context {
|
|||||||
self.emit_event(EventType::SelfavatarChanged);
|
self.emit_event(EventType::SelfavatarChanged);
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
Config::Selfstatus => {
|
|
||||||
let def = stock_str::status_line(self).await;
|
|
||||||
let val = if value.is_none() || value.unwrap() == def {
|
|
||||||
None
|
|
||||||
} else {
|
|
||||||
value
|
|
||||||
};
|
|
||||||
|
|
||||||
self.sql.set_raw_config(key, val).await?;
|
|
||||||
Ok(())
|
|
||||||
}
|
|
||||||
Config::DeleteDeviceAfter => {
|
Config::DeleteDeviceAfter => {
|
||||||
let ret = self
|
let ret = self
|
||||||
.sql
|
.sql
|
||||||
|
|||||||
@@ -3172,10 +3172,7 @@ mod tests {
|
|||||||
assert!(mime.contains(
|
assert!(mime.contains(
|
||||||
"\r\n\
|
"\r\n\
|
||||||
\r\n\
|
\r\n\
|
||||||
Hello mailinglist!\r\n\
|
Hello mailinglist!\r\n"
|
||||||
\r\n\
|
|
||||||
-- \r\n\
|
|
||||||
Sent with my Delta Chat Messenger: https://delta.chat\r\n"
|
|
||||||
));
|
));
|
||||||
|
|
||||||
dc_receive_imf(&t.ctx, DC_MAILINGLIST2, "INBOX", false).await?;
|
dc_receive_imf(&t.ctx, DC_MAILINGLIST2, "INBOX", false).await?;
|
||||||
|
|||||||
@@ -207,7 +207,6 @@ impl<'a> MimeFactory<'a> {
|
|||||||
)
|
)
|
||||||
.await?;
|
.await?;
|
||||||
|
|
||||||
let default_str = stock_str::status_line(context).await;
|
|
||||||
let factory = MimeFactory {
|
let factory = MimeFactory {
|
||||||
from_addr,
|
from_addr,
|
||||||
from_displayname,
|
from_displayname,
|
||||||
@@ -215,7 +214,7 @@ impl<'a> MimeFactory<'a> {
|
|||||||
selfstatus: context
|
selfstatus: context
|
||||||
.get_config(Config::Selfstatus)
|
.get_config(Config::Selfstatus)
|
||||||
.await?
|
.await?
|
||||||
.unwrap_or(default_str),
|
.unwrap_or_default(),
|
||||||
recipients,
|
recipients,
|
||||||
timestamp: msg.timestamp_sort,
|
timestamp: msg.timestamp_sort,
|
||||||
loaded: Loaded::Message { chat },
|
loaded: Loaded::Message { chat },
|
||||||
@@ -246,11 +245,10 @@ impl<'a> MimeFactory<'a> {
|
|||||||
.get_config(Config::Displayname)
|
.get_config(Config::Displayname)
|
||||||
.await?
|
.await?
|
||||||
.unwrap_or_default();
|
.unwrap_or_default();
|
||||||
let default_str = stock_str::status_line(context).await;
|
|
||||||
let selfstatus = context
|
let selfstatus = context
|
||||||
.get_config(Config::Selfstatus)
|
.get_config(Config::Selfstatus)
|
||||||
.await?
|
.await?
|
||||||
.unwrap_or(default_str);
|
.unwrap_or_default();
|
||||||
let timestamp = dc_create_smeared_timestamp(context).await;
|
let timestamp = dc_create_smeared_timestamp(context).await;
|
||||||
|
|
||||||
let res = MimeFactory::<'a> {
|
let res = MimeFactory::<'a> {
|
||||||
|
|||||||
@@ -53,9 +53,6 @@ pub enum StockMessage {
|
|||||||
#[strum(props(fallback = "File"))]
|
#[strum(props(fallback = "File"))]
|
||||||
File = 12,
|
File = 12,
|
||||||
|
|
||||||
#[strum(props(fallback = "Sent with my Delta Chat Messenger: https://delta.chat"))]
|
|
||||||
StatusLine = 13,
|
|
||||||
|
|
||||||
#[strum(props(fallback = "Group name changed from \"%1$s\" to \"%2$s\"."))]
|
#[strum(props(fallback = "Group name changed from \"%1$s\" to \"%2$s\"."))]
|
||||||
MsgGrpName = 15,
|
MsgGrpName = 15,
|
||||||
|
|
||||||
@@ -455,11 +452,6 @@ pub(crate) async fn file(context: &Context) -> String {
|
|||||||
translated(context, StockMessage::File).await
|
translated(context, StockMessage::File).await
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Stock string: `Sent with my Delta Chat Messenger: https://delta.chat`.
|
|
||||||
pub(crate) async fn status_line(context: &Context) -> String {
|
|
||||||
translated(context, StockMessage::StatusLine).await
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Stock string: `Group name changed from "%1$s" to "%2$s".`.
|
/// Stock string: `Group name changed from "%1$s" to "%2$s".`.
|
||||||
pub(crate) async fn msg_grp_name(
|
pub(crate) async fn msg_grp_name(
|
||||||
context: &Context,
|
context: &Context,
|
||||||
|
|||||||
Reference in New Issue
Block a user