feat: resolve nala issue
This commit is contained in:
@@ -212,9 +212,14 @@ export default async (req, res) => {
|
|||||||
.catch((error) => reject(error));
|
.catch((error) => reject(error));
|
||||||
})
|
})
|
||||||
.then((result) => {
|
.then((result) => {
|
||||||
// console.log("NALA<<<<<<<", result)
|
const nalaRates = result.data.find(
|
||||||
|
(data) => {
|
||||||
|
return data.source_currency == "EUR" && data.destination_currency === "NGN"
|
||||||
|
}
|
||||||
|
)
|
||||||
|
// console.log("NALA<<<<<<<", nalaRates)
|
||||||
return {
|
return {
|
||||||
rate: parseFloat(result.data[5].rate).toFixed(2),
|
rate: parseFloat(nalaRates.rate).toFixed(2),
|
||||||
provider: "Nala",
|
provider: "Nala",
|
||||||
bestRate: false,
|
bestRate: false,
|
||||||
href: "https://join.iwantnala.com/JESSE-715106",
|
href: "https://join.iwantnala.com/JESSE-715106",
|
||||||
|
|||||||
Reference in New Issue
Block a user