fixed default collection not being an array
added collapse of chains into their named key/value pairs