fix(together): invite_code を JWT 必須に変更、Guard Web v1 方針を STATUS.md に明記
This commit is contained in:
parent
ef7fccb255
commit
50e95577d7
10
STATUS.md
10
STATUS.md
|
|
@ -31,10 +31,12 @@
|
|||
- **表示 HTML**: DOMPurify + `safeHtml()`、解説の保存時サニタイズ ✓
|
||||
- **学習フロー UX**: 戻る=1枚前、学習フローを終了(理解度保持)、理解度をクリアして学ぶ、`#comprehension-quiz` へスクロール ✓
|
||||
|
||||
### Guard / Tauri
|
||||
1. **Timer → Pulse 連携(セッションログ)** — タイマー終了時にセッション記録モーダル。`posimai-timer-sessions` に保存
|
||||
2. **Tauri アプリ動作確認** — デスクトップショートカットから起動、CodeViewer が WebView でも動くか確認
|
||||
3. **Diff → 履歴保存 + Journal 送信** — 比較結果をlocalStorage保存・Journal連携
|
||||
### Guard(方針確定: Web v1のみ・2026-04-20)
|
||||
**v1 = Web PWA のみ。Tauri・VS Code拡張・CLI はすべて v1 タグ後のロードマップ。**
|
||||
現行の main ブランチは Web のみを対象とする。Tauri/拡張のブランチは統合しない。
|
||||
|
||||
v1 残タスク:
|
||||
1. **Web v1 完了条件の文書化** — 入力・出力・非機能(タイムアウト・APIキー未設定時)・免責表記を検証可能な形で定義する
|
||||
|
||||
### Guard 完成状態(2026-04-14)
|
||||
- ルールエンジン(133ルール)✓
|
||||
|
|
|
|||
|
|
@ -2688,6 +2688,7 @@ ${excerpt}
|
|||
});
|
||||
|
||||
// GET /together/groups/:groupId — グループ情報(メンバーのみ)
|
||||
// invite_code は JWT 認証済みの場合のみ返す(レガシー ?u= のみでは返さない)
|
||||
r.get('/together/groups/:groupId', async (req, res) => {
|
||||
if (!/^[a-zA-Z0-9_-]+$/.test(req.params.groupId)) return res.status(400).json({ error: 'invalid groupId' });
|
||||
const username = normalizeTogetherUsername(req.query.u);
|
||||
|
|
@ -2696,7 +2697,9 @@ ${excerpt}
|
|||
if (!(await togetherEnsureMember(pool, res, req.params.groupId, username, jwtUserId))) return;
|
||||
const result = await pool.query('SELECT id, name, invite_code, created_at FROM together_groups WHERE id=$1', [req.params.groupId]);
|
||||
if (result.rows.length === 0) return res.status(404).json({ error: 'グループが見つかりません' });
|
||||
res.json(result.rows[0]);
|
||||
const row = result.rows[0];
|
||||
if (!jwtUserId) delete row.invite_code;
|
||||
res.json(row);
|
||||
} catch (e) {
|
||||
res.status(500).json({ error: 'Internal server error' });
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue