Remove need for 3rd party lib, fix inconsistencies