Refactor to be prototype driven.