File tree Expand file tree Collapse file tree 3 files changed +19
-11
lines changed
Expand file tree Collapse file tree 3 files changed +19
-11
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ area : webapp
3+ type : fix
4+ ---
5+
6+ Prevent dashboard crash (React error #31 ) when span accessory item text is not a string. Filters out malformed accessory items in SpanCodePathAccessory instead of passing objects to React as children.
Original file line number Diff line number Diff line change @@ -104,16 +104,18 @@ export function SpanCodePathAccessory({
104104 className
105105 ) }
106106 >
107- { accessory . items . map ( ( item , index ) => (
108- < Fragment key = { index } >
109- < span className = { cn ( "truncate" , "text-text-dimmed" ) } > { item . text } </ span >
110- { index < accessory . items . length - 1 && (
111- < span className = "text-text-dimmed" >
112- < ChevronRightIcon className = "size-4" />
113- </ span >
114- ) }
115- </ Fragment >
116- ) ) }
107+ { accessory . items
108+ . filter ( ( item ) => typeof item . text === "string" )
109+ . map ( ( item , index , filtered ) => (
110+ < Fragment key = { index } >
111+ < span className = { cn ( "truncate" , "text-text-dimmed" ) } > { item . text } </ span >
112+ { index < filtered . length - 1 && (
113+ < span className = "text-text-dimmed" >
114+ < ChevronRightIcon className = "size-4" />
115+ </ span >
116+ ) }
117+ </ Fragment >
118+ ) ) }
117119 </ code >
118120 ) ;
119121}
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ export type RealtimeStreamsOptions = {
77 redis : RedisOptions | undefined ;
88 logger ?: Logger ;
99 logLevel ?: LogLevel ;
10- inactivityTimeoutMs ?: number ; // Close stream after this many ms of no new data (default: 60000 )
10+ inactivityTimeoutMs ?: number ; // Close stream after this many ms of no new data (default: 15000 )
1111} ;
1212
1313// Legacy constant for backward compatibility (no longer written, but still recognized when reading)
You can’t perform that action at this time.
0 commit comments