minor bug fixes [skip ci]