message: fix: use X-Forwarded-Host header to create next url
diff: @@ -118,9 +118,7 @@ export async function getWearablesEndpoint(
  },
  { arrayFormat: 'repeat' }
  )
  - const next = nextLastId
  - ? req.protocol + '://' + req.get('host') + req.baseUrl + req.path + '?' + queryParams
  - : undefined
  + const next = nextLastId ? calculateNextUrl(req, queryParams) : undefined
  res.send({ wearables, filters: requestFilters, pagination: { limit: sanitizedLimit, next } })
  } catch (error) {
  @@ -128,6 +126,12 @@ export async function getWearablesEndpoint(
  }
  }
  +function calculateNextUrl(req: Request, queryParams: string) {
  + // When running local the X-Forwarded-Host is absent, as it is set by nginx
  + const host = req.get('X-Forwarded-Host') ?? req.get('Host')
  + return req.protocol + '://' + host + req.baseUrl + req.path + '?' + queryParams
  +}
  +
  /**
  * This function will return a list of wearables that matches the given filters. It will check off-chain, L1 and L2 wearables.
  * The order will be off-chain > L1 > L2.
  