summaryrefslogtreecommitdiffstats
path: root/gateway/samechannel
diff options
context:
space:
mode:
Diffstat (limited to 'gateway/samechannel')
-rw-r--r--gateway/samechannel/samechannel.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/gateway/samechannel/samechannel.go b/gateway/samechannel/samechannel.go
index a4777a60..5ea58b84 100644
--- a/gateway/samechannel/samechannel.go
+++ b/gateway/samechannel/samechannel.go
@@ -73,7 +73,10 @@ func (gw *SameChannelGateway) handleMessage(msg config.Message, dest *bridge.Bri
func (gw *SameChannelGateway) modifyUsername(msg *config.Message, dest *bridge.Bridge) {
br := gw.Bridges[msg.Account]
- nick := dest.Config.RemoteNickFormat
+ nick := gw.Config.General.RemoteNickFormat
+ if nick == "" {
+ nick = dest.Config.RemoteNickFormat
+ }
nick = strings.Replace(nick, "{NICK}", msg.Username, -1)
nick = strings.Replace(nick, "{BRIDGE}", br.Name, -1)
nick = strings.Replace(nick, "{PROTOCOL}", br.Protocol, -1)