Skip to content

Commit

Permalink
fix: panic on empty updater spans
Browse files Browse the repository at this point in the history
  • Loading branch information
CrabNejonas committed Dec 5, 2023
1 parent 908e3f9 commit 229b6b1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion devtools/src/layer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ where
Event::Event {
at,
metadata,
message,
message: message.unwrap_or_default(),
fields,
maybe_parent,
}
Expand Down
7 changes: 2 additions & 5 deletions devtools/src/visitors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,8 @@ impl EventVisitor {
message: None,
}
}
pub(crate) fn result(self) -> (String, Vec<Field>) {
(
self.message.unwrap(), // TODO handle result here
self.field_visitor.result(),
)
pub(crate) fn result(self) -> (Option<String>, Vec<Field>) {
(self.message, self.field_visitor.result())
}
}

Expand Down

0 comments on commit 229b6b1

Please sign in to comment.