Minor bug fix for printing logs