telepathyClient: decline dispatch op when approving unsupported channel type

It shouldn't happen in theory but best to be safe than sorry.

https://bugzilla.gnome.org/show_bug.cgi?id=677457
This commit is contained in:
Guillaume Desmottes 2012-06-05 12:37:06 +02:00
parent 69a63f208e
commit 42366ab025

View File

@ -237,6 +237,8 @@ const Client = new Lang.Class({
this._approveCall(account, conn, channel, dispatchOp, context);
else if (chanType == Tp.IFACE_CHANNEL_TYPE_FILE_TRANSFER)
this._approveFileTransfer(account, conn, channel, dispatchOp, context);
else
Shell.decline_dispatch_op(context, 'Unsupported channel type');
},
_approveTextChannel: function(account, conn, channel, dispatchOp, context) {