Fix output into log