fixed bug in zip method