()
| 1961 | if (this.localuser.focusChannel) { |
| 1962 | this.localuser.focusChannel.infinite.delete(); |
| 1963 | } |
| 1964 | if (this !== this.localuser.focusGuild) { |
| 1965 | this.loadGuild(); |
| 1966 | } |
| 1967 | if (this.localuser.focusChannel && this.localuser.focusChannel.myhtml) { |
| 1968 | this.localuser.focusChannel.myhtml.classList.remove("viewChannel"); |
| 1969 | } |
| 1970 | TypeBox.changeVisablity(false); |
| 1971 | this.prevchannel = undefined; |
| 1972 | this.localuser.focusChannel = undefined; |
| 1973 | } |
| 1974 | noChannel(addstate: boolean) { |
| 1975 | for (const c of this.channels) { |
| 1976 | if (c.visible) { |
| 1977 | this.loadChannel(c.id, addstate); |
| 1978 | return; |
| 1979 | } |
| 1980 | } |
| 1981 | if (addstate) { |
| 1982 | history.pushState([this.id, undefined], "", "/channels/" + this.id); |
| 1983 | } |
| 1984 | this.localuser.pageTitle(I18n.guild.emptytitle()); |
| 1985 | const channelTopic = document.getElementById("channelTopic") as HTMLSpanElement; |
| 1986 | channelTopic.setAttribute("hidden", ""); |
no test coverage detected