Fixed more minor bugs