fix(resources/calls): Fixed save call not saving identifier

This commit is contained in:
Taso committed 2021-02-06 20:02:40 -05:00
1 parent f626d1b0ce
commit 1ac3d89f59
1 file changed
+7 -2
+7 -2
View File
@@ -37,8 +37,13 @@ async function getPlayerFromIdentifier(identifier: string): Promise<XPlayer> {
async function saveCall(call: ICall) {
const query =
'INSERT INTO npwd_calls (transmitter, receiver, start) VALUES (?, ?, ?)';
await pool.query(query, [call.transmitter, call.receiver, call.start]);
'INSERT INTO npwd_calls (identifier, transmitter, receiver, start) VALUES (?, ?, ?, ?)';
await pool.query(query, [
call.identifier,
call.transmitter,
call.receiver,
call.start,
]);
}
async function updateCall(call: ICall, isAccepted: boolean, end: number) {