Handle cancelled file transfer in initial callback.

If the client cancelled a file upload in the initial callback,
we would incorrectly proceed with the handshake.
This commit is contained in:
Juliusz Chroboczek
2024-08-11 17:38:55 +02:00
parent ccb7cb9127
commit dd979652c2
+5
View File
@@ -1871,6 +1871,11 @@ ServerConnection.prototype.sendFile = function(id, file) {
return;
}
if(f.state === 'closed') {
// the client cancelled the transfer
return;
}
sc.transferredFiles[f.fullid()] = f;
sc.userMessage('filetransfer', id, {
type: 'invite',