mirror of
https://github.com/chatmail/core.git
synced 2026-05-16 13:26:38 +03:00
Fix clippy warnings
This commit is contained in:
@@ -193,7 +193,7 @@ impl StockMessage {
|
||||
/// Default untranslated strings for stock messages.
|
||||
///
|
||||
/// These could be used in logging calls, so no logging here.
|
||||
fn fallback(&self) -> &'static str {
|
||||
fn fallback(self) -> &'static str {
|
||||
self.get_str("fallback").unwrap_or_default()
|
||||
}
|
||||
}
|
||||
@@ -238,7 +238,7 @@ impl Context {
|
||||
.unwrap()
|
||||
.get(&(id as usize))
|
||||
{
|
||||
Some(ref x) => Cow::Owned(x.to_string()),
|
||||
Some(ref x) => Cow::Owned((*x).to_string()),
|
||||
None => Cow::Borrowed(id.fallback()),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user