Fixes minor bugs.