Fix bugs which stopped library from working