fix: handle language color null
This commit is contained in:
parent
83f3fbbdcf
commit
b083c4fadd
|
@ -14,6 +14,10 @@ class StorageKeys {
|
|||
}
|
||||
|
||||
Color convertColor(String cssHex) {
|
||||
if (cssHex == null) {
|
||||
return Color(0xffcccccc); // Default color
|
||||
}
|
||||
|
||||
if (cssHex.startsWith('#')) {
|
||||
cssHex = cssHex.substring(1);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue