Minor fixups
fix possible bug