Skip to content

Commit

Permalink
Merge pull request #727 from SnowCait/req-if-exists
Browse files Browse the repository at this point in the history
REQ if exists
  • Loading branch information
SnowCait authored Oct 16, 2023
2 parents 608b2b6 + 7098ce1 commit be458d7
Showing 1 changed file with 17 additions and 13 deletions.
30 changes: 17 additions & 13 deletions web/src/lib/timelines/MainTimeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,19 +31,23 @@ export function referencesReqEmit(event: Event): void {
}

const $eventItemStore = get(eventItemStore);
eventsReq.emit({
ids: [
...new Set([
...event.tags
.filter(
([tagName, id]) =>
tagName === 'e' && id !== undefined && !$eventItemStore.has(id)
)
.map(([, id]) => id),
...Content.findNotesAndNeventsToIds(event.content)
])
]
});
const ids = [
...new Set([
...event.tags
.filter(
([tagName, id]) =>
tagName === 'e' && id !== undefined && !$eventItemStore.has(id)
)
.map(([, id]) => id),
...Content.findNotesAndNeventsToIds(event.content)
])
];

if (ids.length > 0) {
eventsReq.emit({
ids
});
}
}

rxNostr
Expand Down

1 comment on commit be458d7

@vercel
Copy link

@vercel vercel bot commented on be458d7 Oct 16, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

nostter – ./

nostter-snowcait.vercel.app
nostter-git-main-snowcait.vercel.app
nostter.vercel.app

Please sign in to comment.