Fix item sorting