fixed comments for encode/decode