fix bug where last log was not downloaded, and where queued update did not contain ended=True

main
Andy Haden 2018-06-06 21:09:30 -07:00
parent 6e48c6cf66
commit 46e3919aab
2 changed files with 5 additions and 3 deletions

View File

@ -398,7 +398,7 @@ export default class CanExplorer extends Component {
partsLoaded: this.state.partsLoaded + 1
},
() => {
if (part < maxPart) {
if (part <= maxPart) {
this.spawnWorker(parts, {
part: part + 1,
prevMsgEntries,

View File

@ -93,8 +93,10 @@ async function loadData(entry) {
res.on("end", function() {
console.log("Stream ended");
setTimeout(() => (entry.ended = true));
queueBatch(entry);
setTimeout(() => {
entry.ended = true;
queueBatch(entry);
});
});
var msgArr = [];