bug fixed for log