|
|
|
@ -41,13 +41,6 @@ export const ensurePRSummaries = async (repo_id: string) => { |
|
|
|
|
|
|
|
|
|
|
|
sub = ndk.subscribe( |
|
|
|
sub = ndk.subscribe( |
|
|
|
[ |
|
|
|
[ |
|
|
|
{ |
|
|
|
|
|
|
|
kinds: [pr_kind], |
|
|
|
|
|
|
|
'#a': repo.maintainers.map( |
|
|
|
|
|
|
|
(m) => `${repo_kind}:${m.hexpubkey}:${repo.repo_id}` |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
limit: 50, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
{ |
|
|
|
kinds: [patch_kind], |
|
|
|
kinds: [patch_kind], |
|
|
|
'#a': repo.maintainers.map( |
|
|
|
'#a': repo.maintainers.map( |
|
|
|
@ -97,31 +90,6 @@ export const ensurePRSummaries = async (repo_id: string) => { |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
if (event.kind == pr_kind) { |
|
|
|
|
|
|
|
pr_summaries.update((prs) => { |
|
|
|
|
|
|
|
return { |
|
|
|
|
|
|
|
...prs, |
|
|
|
|
|
|
|
summaries: [ |
|
|
|
|
|
|
|
...prs.summaries, |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
...summary_defaults, |
|
|
|
|
|
|
|
id: event.id, |
|
|
|
|
|
|
|
repo_id: repo_id, |
|
|
|
|
|
|
|
title: event.tagValue('name') || '', |
|
|
|
|
|
|
|
descritpion: event.tagValue('description') || '', |
|
|
|
|
|
|
|
created_at: event.created_at, |
|
|
|
|
|
|
|
comments: 0, |
|
|
|
|
|
|
|
author: { |
|
|
|
|
|
|
|
hexpubkey: event.pubkey, |
|
|
|
|
|
|
|
loading: true, |
|
|
|
|
|
|
|
npub: '', |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
loading: false, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
authors_unsubscribers.push( |
|
|
|
authors_unsubscribers.push( |
|
|
|
ensureUser(event.pubkey).subscribe((u: User) => { |
|
|
|
ensureUser(event.pubkey).subscribe((u: User) => { |
|
|
|
|