Changes include some minor bug fixes and simplification of some sections of code.