MCPcopy
hub / github.com/ergochat/ergo / t

Method t

irc/client.go:662–668  ·  view source on GitHub ↗

t returns the translated version of the given string, based on the languages configured by the client.

(originalString string)

Source from the content-addressed store, hash-verified

660
661// t returns the translated version of the given string, based on the languages configured by the client.
662func (client *Client) t(originalString string) string {
663 languageManager := client.server.Config().languageManager
664 if !languageManager.Enabled() {
665 return originalString
666 }
667 return languageManager.Translate(client.Languages(), originalString)
668}
669
670// main client goroutine: read lines and execute the corresponding commands
671// `proxyLine` is the PROXY-before-TLS line, if there was one

Callers 15

getWhoisOfMethod · 0.95
sendHelpMethod · 0.95
doIdentLookupMethod · 0.95
runMethod · 0.95
replayPrivmsgHistoryMethod · 0.95
tryRegisterMethod · 0.80
playRegistrationBurstMethod · 0.80
LusersMethod · 0.80
MOTDMethod · 0.80
applyConfigMethod · 0.80
modesTextGeneratorFunction · 0.80

Calls 4

LanguagesMethod · 0.95
ConfigMethod · 0.80
TranslateMethod · 0.80
EnabledMethod · 0.45

Tested by

no test coverage detected