Rewrote the whole thing!