Added color check to ensure no errors