fix lazy logging issue