Completes some TODOs.
Changes to some formatting.