add send and publish
This commit is contained in:
@@ -349,7 +349,9 @@ impl Community {
|
||||
}
|
||||
|
||||
fn start_round(&mut self, channel: ChannelId, intent: Intent, cx: &mut Context<Self>) {
|
||||
let client = NostrRegistry::global(cx).read(cx).client();
|
||||
let nostr = NostrRegistry::global(cx);
|
||||
let client = nostr.read(cx).client();
|
||||
|
||||
let held = self.held_keys(&channel);
|
||||
let relays = self.state.relays.clone();
|
||||
let pages = self.pages.clone();
|
||||
@@ -498,7 +500,8 @@ impl Community {
|
||||
|
||||
/// Write the local state document out.
|
||||
fn persist(&mut self, cx: &Context<Self>) {
|
||||
let client = NostrRegistry::global(cx).read(cx).client();
|
||||
let nostr = NostrRegistry::global(cx);
|
||||
let client = nostr.read(cx).client();
|
||||
let state = self.state.clone();
|
||||
|
||||
let task = cx.background_spawn(async move {
|
||||
@@ -520,7 +523,9 @@ impl Community {
|
||||
limit: usize,
|
||||
cx: &App,
|
||||
) -> Task<Result<Timeline>> {
|
||||
let client = NostrRegistry::global(cx).read(cx).client();
|
||||
let nostr = NostrRegistry::global(cx);
|
||||
let client = nostr.read(cx).client();
|
||||
|
||||
let channel = *channel;
|
||||
let owner = self.state.owner;
|
||||
let community_id = self.state.id;
|
||||
|
||||
Reference in New Issue
Block a user