- Fix bugs discovered in unit tests