added function for discoloration