diff --git a/pkg/stanza/adapter/converter.go b/pkg/stanza/adapter/converter.go index e007ae4b7fda..0025f54a6573 100644 --- a/pkg/stanza/adapter/converter.go +++ b/pkg/stanza/adapter/converter.go @@ -54,13 +54,6 @@ func ConvertEntries(entries []*entry.Entry) plog.Logs { return pLogs } -// convert converts one entry.Entry into plog.LogRecord allocating it. -func convert(ent *entry.Entry) plog.LogRecord { - dest := plog.NewLogRecord() - convertInto(ent, dest) - return dest -} - // convertInto converts entry.Entry into provided plog.LogRecord. func convertInto(ent *entry.Entry, dest plog.LogRecord) { if !ent.Timestamp.IsZero() { diff --git a/pkg/stanza/adapter/converter_test.go b/pkg/stanza/adapter/converter_test.go index 2da3c2226a2b..66846e0a3915 100644 --- a/pkg/stanza/adapter/converter_test.go +++ b/pkg/stanza/adapter/converter_test.go @@ -961,3 +961,10 @@ func TestGetResourceIDEmptyAndNilAreEqual(t *testing.T) { emptyID := HashResource(map[string]any{}) require.Equal(t, nilID, emptyID) } + +// convert converts one entry.Entry into plog.LogRecord allocating it. +func convert(ent *entry.Entry) plog.LogRecord { + dest := plog.NewLogRecord() + convertInto(ent, dest) + return dest +}