Fixed error problem could lead to mistake show the selected color