Strip whitespace when reading light state.