Bugfix in unpack_item: use type instead of id to determine type of value

Signed-off-by: Michael Kress <m-kress@m-kress.de>
Merge pull request #2 from m-kress/bugfix_ID

Bugfix in unpack_item: use type instead of id to determine type of value