deepCopyTags preserves nil tags slice

This commit is contained in:
Jay
2026-05-22 10:08:10 -04:00
parent 12699a1630
commit c6145d6020
2 changed files with 19 additions and 0 deletions
+3
View File
@@ -41,6 +41,9 @@ func (v ValidatedEvent) Event() Event {
}
func deepCopyTags(tags []Tag) []Tag {
if tags == nil {
return nil
}
cp := make([]Tag, len(tags))
for i, tag := range tags {
tagcp := make(Tag, len(tag))