Troubleshoot JavaScript

- Made several changes to the file to is late why all output to
console.log isn’t showing.