Refactor.
Fixes and updates.