bug fix logging