Skip to content

Commit

Permalink
deps: fix nostr-sdk changes
Browse files Browse the repository at this point in the history
  • Loading branch information
jb55 committed Dec 21, 2023
1 parent 82997c3 commit d24b96c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,13 @@ pub async fn find_note(app: &Notecrumbs, nip19: &Nip19) -> Result<FindNoteResult

loop {
match client.notifications().recv().await? {
RelayPoolNotification::Event(_url, ev) => {
debug!("got event 1 {:?}", ev);
note = Some(ev);
RelayPoolNotification::Event { event, .. } => {
debug!("got event 1 {:?}", event);
note = Some(event);
return Ok(FindNoteResult { note, profile });
}
RelayPoolNotification::RelayStatus { .. } => continue,
RelayPoolNotification::Message(_url, msg) => match msg {
RelayPoolNotification::Message { message, .. } => match message {
RelayMessage::Event { event, .. } => {
if event.kind == Kind::Metadata {
debug!("got profile {:?}", event);
Expand Down
1 change: 1 addition & 0 deletions src/nip19.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ pub fn to_filters(nip19: &Nip19) -> Result<Vec<Filter>, Error> {
.kind(Kind::Metadata)
.limit(1)]),
Nip19::Secret(_sec) => Err(Error::InvalidNip19),
Nip19::Coordinate(_coord) => Err(Error::InvalidNip19),
}
}

Expand Down
1 change: 1 addition & 0 deletions src/render.rs
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,7 @@ pub fn get_render_data(app: &Notecrumbs, target: &Nip19) -> Result<PartialRender
)?)),

Nip19::Secret(_nsec) => Err(Error::InvalidNip19),
Nip19::Coordinate(_coord) => Err(Error::InvalidNip19),
}
}

Expand Down

0 comments on commit d24b96c

Please sign in to comment.