Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

`/enroll`: a stale approval's completion clears a newer link's code

オープン 初心者向け
#912 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
86/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
typescript
領域
frontend

調査の方向性

hosted/src/App.tsx で approve、clearEnrollment、hashchange ハンドラーの takeLink を読むことから始め、次に issue に記載されている approval と 2 番目のリンクのシーケンスを再現します。issue で言及されている App のテストを追加し、関連する App のテストを実行して、approval A を解決すると enrollment コード B が表示されたままになり、A の approval が報告されることを確認します。

索引モデルが issue の本文から書いたものです。

説明

Code: approve and clearEnrollment in hosted/src/App.tsx; the hashchange handler takeLink in the same file.

Failure path: the user clicks Approve for code A, and approveEnrollment(A) is in flight. A second enrollment link opens in the same tab, and hashchange sets enrolling to code B. A's request resolves, and approve calls clearEnrollment(), which sets enrolling to null and replaces the URL. Code B is gone from memory and from the URL, and the notice reads "Approved A". The user has to open link B again. hosted.md -> "Burrow enrollment" says "A fragment change on /enroll takes the new code without reloading". Here a completion that is already in flight undoes that take.

Suggested fix: in approve, clear only if the enrollment still being shown is the one approved (if (enrollingRef.current?.code === code) clearEnrollment()). Otherwise leave B in place and show the A notice. Add an App test: start an approval, fire a hashchange to a new code, resolve the approval, then assert that the new code is still shown.

Found while trimming #904, which had parked this as a spec "Known gap".

🤖 Generated with Claude Code

主要言語
TypeScript
スター
5
フォーク
1
平均マージ
11時間 51分
マージ済み PR(30日)
341

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

diffplug/dormouse のほかの issue

diffplug/dormouse の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。