currency-converter-lt
Advanced tools
Comparing version
13
index.js
@@ -214,13 +214,12 @@ const cheerio = require("cheerio") | ||
.then((html) => { | ||
const fs = require('fs'); | ||
// const fs = require('fs'); | ||
fs.writeFile("a.html", html.body, function(err) { | ||
if(err) { | ||
return console.log(err); | ||
} | ||
console.log("The file was saved!")}) | ||
// fs.writeFile("a.html", html.body, function(err) { | ||
// if(err) { | ||
// return console.log(err); | ||
// } | ||
// console.log("The file was saved!")}) | ||
return cheerio.load(html.body)}) | ||
.then(($) => {return $(".iBp4i").text().split(" ")[0]}) | ||
.then((rates) => { | ||
console.log(rates) | ||
if(rates.includes(",")) | ||
@@ -227,0 +226,0 @@ rates = rates.replaceAll(",", "") |
{ | ||
"name": "currency-converter-lt", | ||
"version": "1.2.2", | ||
"version": "1.2.3", | ||
"description": "A nodejs currency converter library that doesn't require subscribing to any API calls.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
0
-100%21770
-0.02%363
-0.27%