Fix a bug in the symmetrize function