Skip to content

Commit

Permalink
Merge pull request #3425 from LXIF/patch-4
Browse files Browse the repository at this point in the history
Update intercanister.mdx, fix switched names
  • Loading branch information
jessiemongeon1 authored Sep 4, 2024
2 parents 5583602 + f34ad49 commit 2e65972
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/developer-docs/backend/rust/intercanister.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ async fn publish(counter: Counter) {
}
```

In this code, you can see two inter-canister update calls: `fn subscribe(subscriber: Subscriber)` and `async fn publish(counter: Counter)`. The first method allows for the publisher canister to make a call to the subscriber canister and subscribe to topics. The second method allows the publisher canister to publish information on a topic in the subscriber canister.
In this code, you can see two inter-canister update calls: `fn subscribe(subscriber: Subscriber)` and `async fn publish(counter: Counter)`. The first method allows for the subscriber canister to make a call to the publisher canister and subscribe to topics. The second method allows the publisher canister to publish information on a topic in the subscriber canister.

```rust title="src/subscriber/src/lib.rs"
use candid::{CandidType, Principal};
Expand Down Expand Up @@ -173,4 +173,4 @@ The output should resemble the following:

```bash
(2 : nat)
```
```

0 comments on commit 2e65972

Please sign in to comment.