fix console.log() output in terminal