fix bug in items printing