mirror of https://github.com/vector-im/riot-web
Remove now-unused dispatches
parent
820d9c1c25
commit
b1ec430523
|
@ -105,15 +105,6 @@ function _setCallListeners(call) {
|
||||||
call.hangup();
|
call.hangup();
|
||||||
_setCallState(undefined, call.roomId, "ended");
|
_setCallState(undefined, call.roomId, "ended");
|
||||||
});
|
});
|
||||||
call.on('send_event_error', function(err) {
|
|
||||||
if (err.name === "UnknownDeviceError") {
|
|
||||||
dis.dispatch({
|
|
||||||
action: 'unknown_device_error',
|
|
||||||
err: err,
|
|
||||||
room: MatrixClientPeg.get().getRoom(call.roomId),
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
call.on("hangup", function() {
|
call.on("hangup", function() {
|
||||||
_setCallState(undefined, call.roomId, "ended");
|
_setCallState(undefined, call.roomId, "ended");
|
||||||
});
|
});
|
||||||
|
|
|
@ -44,13 +44,6 @@ module.exports = {
|
||||||
// XXX: temporary logging to try to diagnose
|
// XXX: temporary logging to try to diagnose
|
||||||
// https://github.com/vector-im/riot-web/issues/3148
|
// https://github.com/vector-im/riot-web/issues/3148
|
||||||
console.log('Resend got send failure: ' + err.name + '('+err+')');
|
console.log('Resend got send failure: ' + err.name + '('+err+')');
|
||||||
if (err.name === "UnknownDeviceError") {
|
|
||||||
dis.dispatch({
|
|
||||||
action: 'unknown_device_error',
|
|
||||||
err: err,
|
|
||||||
room: room,
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
dis.dispatch({
|
dis.dispatch({
|
||||||
action: 'message_send_failed',
|
action: 'message_send_failed',
|
||||||
|
@ -60,9 +53,5 @@ module.exports = {
|
||||||
},
|
},
|
||||||
removeFromQueue: function(event) {
|
removeFromQueue: function(event) {
|
||||||
MatrixClientPeg.get().cancelPendingEvent(event);
|
MatrixClientPeg.get().cancelPendingEvent(event);
|
||||||
dis.dispatch({
|
|
||||||
action: 'message_send_cancelled',
|
|
||||||
event: event,
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
|
@ -1331,13 +1331,6 @@ module.exports = React.createClass({
|
||||||
cli.sendEvent(roomId, event.getType(), event.getContent()).done(() => {
|
cli.sendEvent(roomId, event.getType(), event.getContent()).done(() => {
|
||||||
dis.dispatch({action: 'message_sent'});
|
dis.dispatch({action: 'message_sent'});
|
||||||
}, (err) => {
|
}, (err) => {
|
||||||
if (err.name === 'UnknownDeviceError') {
|
|
||||||
dis.dispatch({
|
|
||||||
action: 'unknown_device_error',
|
|
||||||
err: err,
|
|
||||||
room: cli.getRoom(roomId),
|
|
||||||
});
|
|
||||||
}
|
|
||||||
dis.dispatch({action: 'message_send_failed'});
|
dis.dispatch({action: 'message_send_failed'});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -932,11 +932,7 @@ module.exports = React.createClass({
|
||||||
file, this.state.room.roomId, MatrixClientPeg.get(),
|
file, this.state.room.roomId, MatrixClientPeg.get(),
|
||||||
).done(undefined, (error) => {
|
).done(undefined, (error) => {
|
||||||
if (error.name === "UnknownDeviceError") {
|
if (error.name === "UnknownDeviceError") {
|
||||||
dis.dispatch({
|
// Let the staus bar handle this
|
||||||
action: 'unknown_device_error',
|
|
||||||
err: error,
|
|
||||||
room: this.state.room,
|
|
||||||
});
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const ErrorDialog = sdk.getComponent("dialogs.ErrorDialog");
|
const ErrorDialog = sdk.getComponent("dialogs.ErrorDialog");
|
||||||
|
|
|
@ -74,13 +74,6 @@ function onSendMessageFailed(err, room) {
|
||||||
// XXX: temporary logging to try to diagnose
|
// XXX: temporary logging to try to diagnose
|
||||||
// https://github.com/vector-im/riot-web/issues/3148
|
// https://github.com/vector-im/riot-web/issues/3148
|
||||||
console.log('MessageComposer got send failure: ' + err.name + '('+err+')');
|
console.log('MessageComposer got send failure: ' + err.name + '('+err+')');
|
||||||
if (err.name === "UnknownDeviceError") {
|
|
||||||
dis.dispatch({
|
|
||||||
action: 'unknown_device_error',
|
|
||||||
err: err,
|
|
||||||
room: room,
|
|
||||||
});
|
|
||||||
}
|
|
||||||
dis.dispatch({
|
dis.dispatch({
|
||||||
action: 'message_send_failed',
|
action: 'message_send_failed',
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue