Refactored, now fix errors