File tree Expand file tree Collapse file tree 1 file changed +21
-19
lines changed
services/static-webserver/client/source/class/osparc/ui/basic Expand file tree Collapse file tree 1 file changed +21
-19
lines changed Original file line number Diff line number Diff line change @@ -39,25 +39,27 @@ qx.Class.define("osparc.ui.basic.Chip", {
3939
4040 members : {
4141 __applyStatusColor : function ( status ) {
42- switch ( status . toLowerCase ( ) ) {
43- case this . self ( ) . STATUS . SUCCESS :
44- this . set ( {
45- textColor : "white" ,
46- backgroundColor : "product-color" ,
47- } ) ;
48- break ;
49- case this . self ( ) . STATUS . WARNING :
50- this . set ( {
51- textColor : "black" ,
52- backgroundColor : "warning-yellow" ,
53- } ) ;
54- break ;
55- case this . self ( ) . STATUS . ERROR :
56- this . set ( {
57- textColor : "black" ,
58- backgroundColor : "failed-red" ,
59- } ) ;
60- break ;
42+ if ( status ) {
43+ switch ( status . toLowerCase ( ) ) {
44+ case this . self ( ) . STATUS . SUCCESS :
45+ this . set ( {
46+ textColor : "white" ,
47+ backgroundColor : "product-color" ,
48+ } ) ;
49+ break ;
50+ case this . self ( ) . STATUS . WARNING :
51+ this . set ( {
52+ textColor : "black" ,
53+ backgroundColor : "warning-yellow" ,
54+ } ) ;
55+ break ;
56+ case this . self ( ) . STATUS . ERROR :
57+ this . set ( {
58+ textColor : "black" ,
59+ backgroundColor : "failed-red" ,
60+ } ) ;
61+ break ;
62+ }
6163 }
6264 } ,
6365 } ,
You can’t perform that action at this time.
0 commit comments