Tengo dificultades para acceder a la variable currentPrice fuera de esta llamada a la API. ¿Cómo se hace?
var currentPrice //Get the curent market price var marketSymobl = checkOrders[i].symbol.split(" - ")[0].toUpperCase() console.log(checkOrders[i].symbol) finnhubClient.quote(marketSymobl, (error, data, response) => { currentPrice = data.c }); console.log(currentPrice)