Refactor complete; One bug remaining.