Skip to content

Commit

Permalink
clippy: fix a few warnings
Browse files Browse the repository at this point in the history
Signed-off-by: William Casarin <[email protected]>
  • Loading branch information
jb55 committed Apr 27, 2024
1 parent 52e1d86 commit 330d00b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/util/nip10.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ pub struct NoteIdRefBuf {
pub marker: Option<Marker>,
}

fn tag_to_note_id_ref<'a>(tag: Tag<'a>, marker: Option<Marker>, index: i32) -> NoteIdRef<'a> {
fn tag_to_note_id_ref(tag: Tag<'_>, marker: Option<Marker>, index: i32) -> NoteIdRef<'_> {
let id = tag
.get_unchecked(1)
.variant()
Expand Down Expand Up @@ -245,7 +245,7 @@ pub fn tag_to_noteid_ref(tag: Tag<'_>, index: u16) -> Result<NoteIdRef<'_>, Erro
let relay = tag
.get(2)
.and_then(|t| t.variant().str())
.filter(|x| *x != "");
.filter(|x| !x.is_empty());
let marker = tag
.get(3)
.and_then(|t| t.variant().str())
Expand Down

0 comments on commit 330d00b

Please sign in to comment.