add support for sorting arrays of items