some minor bugs