Permalink
Browse files

upload only on match end

  • Loading branch information...
Manuel-777 committed Jan 16, 2019
1 parent 10f49f7 commit d7990f8ed26c2452feb12c7384f074ecc85a6ac6
Showing with 5 additions and 3 deletions.
  1. +4 −2 window_background/background.js
  2. +1 −1 window_background/labels.js
@@ -1510,7 +1510,7 @@ function saveCourse(json) {
}

//
function saveMatch() {
function saveMatch(upload = true) {
if (currentMatchTime == 0) {
return;
}
@@ -1559,7 +1559,9 @@ function saveMatch() {

history[currentMatchId] = match;
history[currentMatchId].type = "match";
httpApi.httpSetMatch(match);
if (upload) {
httpApi.httpSetMatch(match);
}
requestHistorySend(0);
ipc_send("set_timer", 0, windowOverlay);
ipc_send("popup", {"text": "Match saved!", "time": 3000});
@@ -13,7 +13,7 @@ function onLabelOutLogInfo(entry, json) {
oppWin += 1;
}
currentMatchTime += time;
saveMatch();
saveMatch(false);
}
}
}

0 comments on commit d7990f8

Please sign in to comment.