mirror of
https://github.com/chatmail/core.git
synced 2026-05-01 20:36:31 +03:00
Remove useless argument of logging macros
Previously, logging macros (info! warn! error!) accepted integer argument (data1), that was passed to callback function verbatim. In all call sites this argument was 0. With this change, that data1 argument is no longer part of macro interface, 0 is always passed to callback in internals of these macros.
This commit is contained in:
@@ -308,7 +308,6 @@ impl<'a> Contact<'a> {
|
||||
if !may_be_valid_addr(&addr) {
|
||||
warn!(
|
||||
context,
|
||||
0,
|
||||
"Bad address \"{}\" for contact \"{}\".",
|
||||
addr,
|
||||
if !name.as_ref().is_empty() {
|
||||
@@ -404,7 +403,7 @@ impl<'a> Contact<'a> {
|
||||
row_id = sql::get_rowid(context, &context.sql, "contacts", "addr", addr);
|
||||
sth_modified = Modifier::Created;
|
||||
} else {
|
||||
error!(context, 0, "Cannot add contact.");
|
||||
error!(context, "Cannot add contact.");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -683,7 +682,7 @@ impl<'a> Contact<'a> {
|
||||
return Ok(());
|
||||
}
|
||||
Err(err) => {
|
||||
error!(context, 0, "delete_contact {} failed ({})", contact_id, err);
|
||||
error!(context, "delete_contact {} failed ({})", contact_id, err);
|
||||
return Err(err);
|
||||
}
|
||||
}
|
||||
@@ -691,7 +690,7 @@ impl<'a> Contact<'a> {
|
||||
|
||||
info!(
|
||||
context,
|
||||
0, "could not delete contact {}, there are {} messages with it", contact_id, count_msgs
|
||||
"could not delete contact {}, there are {} messages with it", contact_id, count_msgs
|
||||
);
|
||||
bail!("Could not delete contact with messages in it");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user