Wrong encoding of attributes fixed