Updating console.log to use JSON.stringify for printing to console.