[ticket/11538] Fix incorrect regex and test for duplicate # in color string

PHPBB3-11538