Fixed bug when setting color