How electrochemical compounds protect LEDs from environmental conditions