factor out the decoding