Merged with master. Sorting and object type functionality.