decoding bugfix