fixing various inconsistencies within the library