aboutsummaryrefslogtreecommitdiffstats
path: root/filamento/src/logic/process_stanza.rs
diff options
context:
space:
mode:
authorLibravatar cel 🌸 <cel@bunny.garden>2025-05-12 18:29:03 +0100
committerLibravatar cel 🌸 <cel@bunny.garden>2025-05-12 18:29:03 +0100
commitf1540591930aff9d9f584e6ce028c2e49cba1be2 (patch)
treedacbb84b9bc2759ee65a3c3db91ae6d3d6704a42 /filamento/src/logic/process_stanza.rs
parent8c4cee9a622b026aa231dbdf590480786d142ea2 (diff)
downloadluz-f1540591930aff9d9f584e6ce028c2e49cba1be2.tar.gz
luz-f1540591930aff9d9f584e6ce028c2e49cba1be2.tar.bz2
luz-f1540591930aff9d9f584e6ce028c2e49cba1be2.zip
fix(filamento): stanza error panic
Diffstat (limited to '')
-rw-r--r--filamento/src/logic/process_stanza.rs8
1 files changed, 1 insertions, 7 deletions
diff --git a/filamento/src/logic/process_stanza.rs b/filamento/src/logic/process_stanza.rs
index 3bc4b8c..30d0830 100644
--- a/filamento/src/logic/process_stanza.rs
+++ b/filamento/src/logic/process_stanza.rs
@@ -479,13 +479,7 @@ pub async fn recv_presence(
stanza::client::presence::PresenceType::Error => {
// TODO: is there any other information that should go with the error? also MUST have an error, otherwise it's a different error. maybe it shoulnd't be an option.
// TODO: ughhhhhhhhhhhhh these stanza errors should probably just have an option, and custom display
- Err(PresenceError::StanzaError(
- presence
- .errors
- .first()
- .cloned()
- .expect("error MUST have error"),
- ))
+ Err(PresenceError::StanzaError(presence.errors.first().cloned()))
}
// should not happen (error to server)
stanza::client::presence::PresenceType::Probe => {