fix a log bug