Remove App.isChannel

Replace all remaining usage with Client.isChannel. Client will be
able to use the ISUPPORT tokens to check if a name is a channel.
This commit is contained in:
Simon Ser 2021-06-04 19:13:59 +02:00
parent 87588abf27
commit db7aa337cb
2 changed files with 5 additions and 10 deletions

View file

@ -11,7 +11,7 @@ function getActiveClient(app) {
function getActiveChannel(app) {
var activeBuffer = app.state.buffers.get(app.state.activeBuffer);
if (!activeBuffer || !app.isChannel(activeBuffer.name)) {
if (!activeBuffer || activeBuffer.type !== BufferType.CHANNEL) {
throw new Error("Not in a channel");
}
return activeBuffer.name;