Pretty-print buffer name in buffer header
This commit is contained in:
parent
6e16163103
commit
bc7162ebe2
3 changed files with 24 additions and 19 deletions
16
state.js
16
state.js
|
@ -54,3 +54,19 @@ export function getMessageURL(buf, msg) {
|
|||
return bufURL + "?timestamp=" + encodeURIComponent(msg.tags.time);
|
||||
}
|
||||
}
|
||||
|
||||
export function getNetworkName(network, bouncerNetwork, isBouncer) {
|
||||
if (bouncerNetwork && bouncerNetwork.name) {
|
||||
return bouncerNetwork.name;
|
||||
}
|
||||
if (isBouncer) {
|
||||
return "bouncer";
|
||||
}
|
||||
|
||||
var netName = network.isupport.get("NETWORK");
|
||||
if (netName) {
|
||||
return netName;
|
||||
}
|
||||
|
||||
return "server";
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue