Fix logging error