[TouchBar Widget] Setting Wrong Color will continuously crash the BTT app. Cannot open back again.

Describe the bug

When setting up a touchbar widget, setting a "wrong" color will crash the BTT app. The bigger problem is that you cannot open it up again, as it will open for a second and crash again, so you'll have no time to fix the mistake.

For instance, having an apple script like so:

return "{\"text\":\"" & "some text" & "\", \"font_color\": \"255,0,0\"}"

#instead of 

return "{\"text\":\"" & "some text" & "\", \"font_color\": \"255,0,0,255\"}"

I thought RGB would work too. Haven't tested anything else as I just managed to remove the "bad" widget after several restarts thanks to that loading time.

Affected input device (e.g. MacBook Trackpad, Magic Mouse/Trackpad, Touch Bar, etc.): Macbook Touch Bar

Device information:

  • Type of Mac: Macbook Pro 15" 2018
  • macOS version: 10.14.4
  • BetterTouchTool version: 2.760

It seems to be looking for the 4th element in the color code (255,0,0,[thisOne]) without checking if there are actually 4 elements there. I would expect it to work with RGB only as well and default the alpha value
to zero transparency (255).

Thanks for reporting!