Fixed bugs on getColor method