some minor bug fix