Don't insert duplicate codes in tracking history

master
Skylar Ittner 5 years ago
parent 976f44a4f8
commit f3f3653d2c

@ -94,7 +94,7 @@ function openTrackingHistory(code) {
} else { } else {
history = JSON.parse(history); history = JSON.parse(history);
} }
if (infocontext.code != "") { if (infocontext.code != "" && !history.includes(infocontext.code)) {
history.push(infocontext.code); history.push(infocontext.code);
} }
while (history.length > 5) { while (history.length > 5) {

Loading…
Cancel
Save