refactor, see PR notes
fix typos
Merge pull request #12 from pelias/overhaul

Overhaul