complete rewrite. The old version did too much and didn't actually work
1.0.0