fix readme, make errors extend Error, make unnecessary public constant p...

...rivate and update associated unit tests