added collapse to addresses, fixed misc bugs