completely refactored, completely TDD, far simple, some functionality removed