mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
fixed a bug with attempts and chat index
This commit is contained in:
parent
5da63c197f
commit
48e5252a7c
1 changed files with 6 additions and 8 deletions
|
@ -820,8 +820,8 @@ ipcRenderer.on("action-new-msg-received", (event, arg) => {
|
||||||
obj.command = "ping";
|
obj.command = "ping";
|
||||||
obj.checksum = "null";
|
obj.checksum = "null";
|
||||||
obj.msg = "null";
|
obj.msg = "null";
|
||||||
obj.status = item.status; obj.hmac_signed = item.hmac_signed;
|
obj.status = item.status;
|
||||||
|
obj.hmac_signed = item.hmac_signed;
|
||||||
obj.snr = item.snr;
|
obj.snr = item.snr;
|
||||||
obj.type = "ping";
|
obj.type = "ping";
|
||||||
obj.filename = "null";
|
obj.filename = "null";
|
||||||
|
@ -1009,7 +1009,7 @@ ipcRenderer.on("action-new-msg-received", (event, arg) => {
|
||||||
|
|
||||||
//getSetUserInformation(selected_callsign);
|
//getSetUserInformation(selected_callsign);
|
||||||
} else if (splitted_data[1] == "res-2") {
|
} else if (splitted_data[1] == "res-2") {
|
||||||
console.log("In received respons-2");
|
console.log("In received response-2");
|
||||||
let sharedFileInfo = splitted_data[2].split("/", 2);
|
let sharedFileInfo = splitted_data[2].split("/", 2);
|
||||||
|
|
||||||
obj.uuid = uuidv4().toString();
|
obj.uuid = uuidv4().toString();
|
||||||
|
@ -1053,16 +1053,13 @@ update_chat = function (obj) {
|
||||||
}
|
}
|
||||||
return doc;
|
return doc;
|
||||||
});
|
});
|
||||||
obj.attempt = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
// define attempts
|
|
||||||
if (typeof obj.attempt == "undefined") {
|
|
||||||
var attempt = 1;
|
var attempt = 1;
|
||||||
|
obj.attempt = attempt;
|
||||||
} else {
|
} else {
|
||||||
var attempt = obj.attempt;
|
var attempt = obj.attempt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// add percent and bytes per minute if not existing
|
// add percent and bytes per minute if not existing
|
||||||
//console.log(obj.percent)
|
//console.log(obj.percent)
|
||||||
if (typeof obj.percent == "undefined") {
|
if (typeof obj.percent == "undefined") {
|
||||||
|
@ -2194,6 +2191,7 @@ function createChatIndex() {
|
||||||
"status",
|
"status",
|
||||||
"percent",
|
"percent",
|
||||||
"attempt",
|
"attempt",
|
||||||
|
"hmac_signed",
|
||||||
"bytesperminute",
|
"bytesperminute",
|
||||||
"_attachments",
|
"_attachments",
|
||||||
"new",
|
"new",
|
||||||
|
|
Loading…
Reference in a new issue