mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2026-11-13 12:16:54 +00:00
style: Resolve clippy warnings in database and service
This commit is contained in:
2 files changed
+4
-7
No files matched your search
+2
-2
@@ -192,13 +192,13 @@ impl<W: Write> ser::Serializer for &mut Serializer<'_, W> {
|
||||
);
|
||||
|
||||
match name {
|
||||
| "Json" => serde_json::to_writer(&mut self.out, value).map_err(Into::into),
|
||||
| "Json" => serde_json::to_writer(&mut *self.out, value).map_err(Into::into),
|
||||
| "Cbor" => {
|
||||
use minicbor::encode::write::Writer;
|
||||
use minicbor_serde::Serializer;
|
||||
|
||||
value
|
||||
.serialize(&mut Serializer::new(&mut Writer::new(&mut self.out)))
|
||||
.serialize(&mut Serializer::new(&mut Writer::new(&mut *self.out)))
|
||||
.map_err(|e| Self::Error::SerdeSer(e.to_string().into()))
|
||||
},
|
||||
| _ => unhandled!("Unrecognized serialization Newtype {name:?}"),
|
||||
|
||||
@@ -459,21 +459,18 @@ impl Service {
|
||||
push_key.to_owned(),
|
||||
))
|
||||
.await;
|
||||
|
||||
Ok(())
|
||||
},
|
||||
| (Some(appservice_id), None, None) => {
|
||||
self.db
|
||||
.delete_all_requests_for(&Destination::Appservice(appservice_id.to_owned()))
|
||||
.await;
|
||||
|
||||
Ok(())
|
||||
},
|
||||
| _ => {
|
||||
debug_warn!("cleanup_events called with too many or too few arguments");
|
||||
Ok(())
|
||||
},
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn dispatch(&self, msg: Msg) -> Result {
|
||||
|
||||
Reference in new issue
Block a user