Flattens code. Reorganizes code.

yaya