mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 12:19:41 +00:00
Handle single-error rejections when sending messages
We can not assume that we will get back an error array. Closes #258 // FREEBIE
This commit is contained in:
@@ -100,6 +100,9 @@
|
||||
message.unset('pending');
|
||||
message.save();
|
||||
}.bind(this)).catch(function(errors) {
|
||||
if (errors instanceof Error) {
|
||||
errors = [errors];
|
||||
}
|
||||
var keyErrors = [];
|
||||
_.each(errors, function(e) {
|
||||
if (e.error.name === 'OutgoingIdentityKeyError') {
|
||||
|
||||
Reference in New Issue
Block a user