Fix decoding of enums. Closes #4