Restructuring
Whoops, fix stack overflow
More rearranging