Skip to content

Commit

Permalink
feat: patch too
Browse files Browse the repository at this point in the history
  • Loading branch information
zugdev committed Jan 6, 2025
1 parent a2bf783 commit 1ae553d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/home/rendering/render-github-notifications.ts
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,12 @@ async function updateLatestCommentUrls(notificationsToUpdate: { element: HTMLEle
issueElement.addEventListener("click", async() => {
window.open(url, "_blank");
try{
await octokit.request('PATCH /notifications/threads/{thread_id}', {
thread_id: Number(notification.notification.id),
headers: {
'X-GitHub-Api-Version': '2022-11-28'
}
})
await octokit.request('DELETE /notifications/threads/{thread_id}', {
thread_id: Number(notification.notification.id),
headers: {
Expand Down

0 comments on commit 1ae553d

Please sign in to comment.