fixed packing bug