Block colour from Formular

I have this cool widget which changes the color based on my music. But if the cover of the music is dominant white it has the same colour as the text. I dont want my text to change colour. Is it possible to block out the colour white from formular and replace it with black?

I am using this formula

$bp(dominant, mi(cover))$

I cant upload a video here on this forum but i have one on my reddit post

https://www.reddit.com/r/kustom/s/WFVbXkgrMy

Off the top of my head, I would try to break down rhe returned dominant color into its RGB values using tc(cut, start, length). Id then convert from hex to decimal, use some ifs and compare rhe RGB values against fixed values rhat are not too bright, or even substitute them with lower ones to produce a darker variaton of the color.

For example, white is: FFFFFF which in turn when broken down to decimal RGB values is 255, 255, 255.
Id set a limit of 200 for example, and get back the color C8C8C8