Reporting a message inside a thread crashes the chat

オープン
#1,465 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

@Jaivansh-777 がすでに取り組んでいます。

2026年11月27日 から。

  • #1467 @Jaivansh-777 による — オープン

評価

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

調査の方向性

Start with packages/react/src/views/Thread/ThreadMessageList.js and compare how it passes the reported message with MessageList; inspect ReportWindowButtons and messageDescription for the failing call. Done means reporting a message from a thread opens the preview without crashing. A linked pull request is already open, so the work appears underway.

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

説明

bug
Description:

Reporting a message from inside a thread crashes EmbeddedChat.

In packages/react/src/views/Thread/ThreadMessageList.js the report window is rendered as <MessageReportWindow messageId={messageToReport} />, without the message prop. MessageList passes message={reportedMessage}, but the thread view doesn't. ReportWindowButtons then calls messageDescription(message) with undefined, and if (msg.file) throws.

ChatBody renders either ThreadMessageList or MessageList, so inside a thread this is the only report window and it fails every time. There's no error boundary, so the whole widget goes blank.

Steps to reproduce:
  1. Open a thread
  2. Open the message toolbox on any message in the thread and click "Report"
Expected behavior:

The report window opens with the message preview, same as in the main chat.

Actual behavior:

TypeError: Cannot read properties of undefined (reading 'file') and the chat crashes.

I have a small fix ready (look up the reported message from the thread's messages and pass it in, plus a null check in messageDescription) and will open a PR.

主要言語
JavaScript
スター
171
フォーク
421
平均マージ
3日 6時間
マージ済み PR(30日)
4

環境構築

  • Dockerfile・Docker Compose ファイルなし
  • プルリクエストのテンプレートあり
  • コントリビューションガイドなし

はじめの一歩

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

RocketChat/EmbeddedChat のほかの issue

RocketChat/EmbeddedChat の issue をすべて見る

似ている issue

JavaScript の issue をもっと見る

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

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