Getting 404 Response on getNFT's sdk route

Hello, I am using the Moralis SDK and node/express to display a specific user’s nft. I followed this tutorial, but I am getting a “failed to load resource server responded with a status of 404” when I test the route. Does anyone know where I am going wrong? Thanks!

const router = require('express').Router()
const Moralis = require('moralis/node')
const fixURL = require('../utils/fixURL')
const axios = require('axios')
require('dotenv').config()
const serverUrl = process.env.serverUrl
const appId = process.env.appId
router.get('/dashboard/nfts/1', async (req, res) => {
  try {
    const options = { chain: 'eth', address: '0x8a08e3Ce6CED24d376a13C544E45d4DDa02FaFEA' }
    await Moralis.start({ serverUrl, appId })
    const userNFTs = await Moralis.Web3API.account.getNFTs(options)
    userNFTs.forEach(async function (nft) {
      let url = fixURL(nft.token_uri)
      const { data } = await axios.get(url)
      res.json(data)
    })
  } catch (err) {
    res.status(500).json({ error: err })
  }
})

In my code for fixURL I have

module.exports = function fixURL(url) {
  if (url.startsWith("ipfs")) {
    return 'https://ipfs.moralis.io:2053/ipfs/' + url.split('ipfs://ipfs/').slice(-1)
  } else {
    return url + '?format=json'
  }
}

what is the url that returns 404?

I changed the code around and now I am getting a 500 error
the server url is: https://dma5wmaeradr.usemoralis.com:2053/server

router.get('/usernfts', async (req, res) => {
  try {
    const options = { chain: 'eth', address: '0x8a08e3Ce6CED24d376a13C544E45d4DDa02FaFEA' }
    await Moralis.start({ serverUrl, appId })
    const userNFTs = await Moralis.Web3API.account.getNFTs(options)
    userNFTs.forEach(async function (nft) {
      let url = fixURL(nft.token_uri)
      const { data } = await axios.get(url)
      res.json(data)
    })
  } catch (err) {
    res.status(500).json({ error: err })
  }
})

Is that error coming from fetching the token URIs? E.g. remove the forEach and just send the userNFTs as the response.

yes it works well when I remove that thanks!