File tree Expand file tree Collapse file tree 1 file changed +18
-6
lines changed
src/electron/frontend/core/components Expand file tree Collapse file tree 1 file changed +18
-6
lines changed Original file line number Diff line number Diff line change @@ -669,13 +669,24 @@ export class Table extends LitElement {
669669 if ( cell ) {
670670 let message = "" ;
671671 let theme = "" ;
672- if ( warnings . length ) {
673- ( ( theme = "warning" ) , ( message = warnings . map ( ( error ) => error . message ) . join ( "\n" ) ) ) ;
674- } else cell . removeAttribute ( "warning" ) ;
672+ if ( warnings . length > 0 ) {
673+ theme = "warning" ;
674+ message = warnings
675+ . map ( error => error . message )
676+ . join ( "\n" ) ;
677+ } else {
678+ cell . removeAttribute ( "warning" ) ;
679+ }
675680
676- if ( errors . length ) {
677- ( ( theme = "error" ) , ( message = errors . map ( ( error ) => error . message ) . join ( "\n" ) ) ) ; // Class switching handled automatically
678- } else cell . removeAttribute ( "error" ) ;
681+ if ( errors . length > 0 ) {
682+ theme = "error" ;
683+ // Class switching handled automatically
684+ message = errors
685+ . map ( error => error . message )
686+ . join ( "\n" ) ;
687+ } else {
688+ cell . removeAttribute ( "error" ) ;
689+ }
679690
680691 if ( theme ) cell . setAttribute ( theme , "" ) ;
681692
@@ -731,3 +742,4 @@ export class Table extends LitElement {
731742}
732743
733744customElements . get ( "nwb-table" ) || customElements . define ( "nwb-table" , Table ) ;
745+
You can’t perform that action at this time.
0 commit comments