try to factor out unpack2
one line of code is better than 0