Skip to content

Commit

Permalink
Merge pull request #101 from holochain/signal-08-20
Browse files Browse the repository at this point in the history
handle system signals
  • Loading branch information
ThetaSinner authored Aug 20, 2024
2 parents 5485d2f + 858ea62 commit aafc004
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/app_websocket.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,13 +86,12 @@ impl AppWebsocket {
) -> Result<String> {
let app_info = self.app_info.clone();
self.inner
.on_signal(move |signal| {
if let Signal::App {
.on_signal(move |signal| match signal.clone() {
Signal::App {
cell_id,
zome_name: _,
signal: _,
} = signal.clone()
{
} => {
if app_info.cell_info.values().any(|cells| {
cells.iter().any(|cell_info| match cell_info {
CellInfo::Provisioned(cell) => cell.cell_id.eq(&cell_id),
Expand All @@ -103,6 +102,7 @@ impl AppWebsocket {
handler(signal);
}
}
Signal::System(_) => handler(signal),
})
.await
}
Expand Down

0 comments on commit aafc004

Please sign in to comment.