MCPcopy
hub / github.com/tuna/tunasync / formatMessage

Function formatMessage

internal/logger.go:270–281  ·  view source on GitHub ↗
(format string, args ...any)

Source from the content-addressed store, hash-verified

268}
269
270func formatMessage(format string, args ...any) string {
271 if len(args) == 0 {
272 return format
273 }
274 if strings.Contains(format, "%") {
275 return fmt.Sprintf(format, args...)
276 }
277 items := make([]any, 0, len(args)+1)
278 items = append(items, format)
279 items = append(items, args...)
280 return fmt.Sprint(items...)
281}

Callers 7

TestLoggerHelpersFunction · 0.85
DebugfMethod · 0.85
InfofMethod · 0.85
NoticefMethod · 0.85
WarningfMethod · 0.85
ErrorfMethod · 0.85
PanicfMethod · 0.85

Calls

no outgoing calls

Tested by 1

TestLoggerHelpersFunction · 0.68