btlqql opened a new pull request, #2263: URL: https://github.com/apache/rocketmq-dashboard/pull/2263
## Problem Consumer and alert views assume nullable API collections are always present. The same consumer topic can also appear with different filter expressions while the tables use only the topic name as their React row key. ## Root cause Rendering calls `.length` and `.map` directly on optional collections, and the subscription tables use a non-unique key for rows that are distinct by filter mode and expression. ## Changes - normalize missing `subscribedTopics` and alert `channels` to empty arrays while rendering - use a composite subscription key of topic, filter mode, and expression in both tables This consolidates the related defensive-rendering fixes from closed PRs #2090 and #2091 into one cohesive PR, following the maintainer guidance in #2107. ## Impact The affected views no longer crash on valid nullable responses, and React can reconcile distinct subscription rows reliably. ## Validation - `npm test -- src/pages/instance/__tests__/ConsumerPage.test.tsx src/pages/ops/__tests__/AlertsPage.test.tsx` (18 tests passed) - ESLint on all changed files - `npm run build` - `git diff --check` Closes #2072. Closes #2073. Closes #2074. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
