File reading bugs fixed

master
sigonasr2 2 years ago
parent b54bbd9994
commit e92c273d26
  1. 2
      inventory_monitor.js

@ -11,6 +11,7 @@ function update(){
fs.readFile("C:\\Users\\sigon\\Documents\\memory",
(err,data)=>{
var fileContents = data.toString().split("\n");
if (fileContents.length>=387){
for (i=0;i<fileContents.length;i++){
line=fileContents[i]
item=line.split(" ")
@ -35,6 +36,7 @@ function update(){
axios.post("http://projectdivar.com/inventoryData",finalData)
}
firstLoad=false
}
setTimeout(update,1000)
})
}

Loading…
Cancel
Save