Minor changes to the way types and indexes are handled