From aabae52169ec05cbb07b98ca8f49921333c65e63 Mon Sep 17 00:00:00 2001 From: Runxi Yu Date: Sat, 22 Mar 2025 10:41:38 +0800 Subject: [PATCH] Use Source by value instead of pointer --- message.go | 5 ++--- diff --git a/message.go b/message.go index 190c198001fb330e91abd077c0362b2a90d0d06f..ffb29e87e122e4846891359e129f7b67d96d7a34 100644 --- a/message.go +++ b/message.go @@ -10,7 +10,7 @@ ) type Message struct { Command string - Source *Source + Source Source Tags map[string]string Args []string } @@ -47,8 +47,7 @@ return } sp[0] = sp[0][1:] - source := parseSource(sp[0]) - msg.Source = &source + msg.Source = parseSource(sp[0]) if len(sp) < 2 { err = ErrMalformedMsg -- 2.48.1