mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
Fix for UUID tweak
This commit is contained in:
parent
1b5f9f11a6
commit
5ef59d3563
2 changed files with 7 additions and 8 deletions
|
@ -331,6 +331,12 @@ db.post({
|
||||||
|
|
||||||
document.getElementById('selectFilesButton').innerHTML = ``;
|
document.getElementById('selectFilesButton').innerHTML = ``;
|
||||||
var uuid = uuidv4();
|
var uuid = uuidv4();
|
||||||
|
let uuidlast = uuid.lastIndexOf('-');
|
||||||
|
uuidlast +=1;
|
||||||
|
if (uuidlast > 0)
|
||||||
|
{
|
||||||
|
uuid = uuid.substring(uuidlast);
|
||||||
|
}
|
||||||
console.log(data_with_attachment)
|
console.log(data_with_attachment)
|
||||||
let Data = {
|
let Data = {
|
||||||
command: "send_message",
|
command: "send_message",
|
||||||
|
|
|
@ -543,14 +543,7 @@ exports.sendMessage = function(dxcallsign, mode, frames, data, checksum, uuid, c
|
||||||
|
|
||||||
//socketLog.info(data)
|
//socketLog.info(data)
|
||||||
//shorten uuid
|
//shorten uuid
|
||||||
let uuidlast = uuid.lastIndexOf('-');
|
|
||||||
uuidlast +=1;
|
|
||||||
if (uuidlast > 0)
|
|
||||||
{
|
|
||||||
uuid = uuid.substr(uuidlast);
|
|
||||||
//console.log("UUID shortened to: ",uuid);
|
|
||||||
}
|
|
||||||
|
|
||||||
var datatype = "m"
|
var datatype = "m"
|
||||||
data = datatype + split_char + command + split_char + checksum + split_char + uuid + split_char + data
|
data = datatype + split_char + command + split_char + checksum + split_char + uuid + split_char + data
|
||||||
//socketLog.info(data)
|
//socketLog.info(data)
|
||||||
|
|
Loading…
Reference in a new issue