From 91cbcd589e7c4ab87e5994e4d0276ea1248dc5c2 Mon Sep 17 00:00:00 2001 From: kim <89579420+NyaaaWhatsUpDoc@users.noreply.github.com> Date: Thu, 10 Aug 2023 15:08:41 +0100 Subject: [performance] remove last of relational queries to instead rely on caches (#2091) --- internal/typeutils/internaltofrontend.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'internal/typeutils/internaltofrontend.go') diff --git a/internal/typeutils/internaltofrontend.go b/internal/typeutils/internaltofrontend.go index 2dc0e4dd5..ab04f6ccc 100644 --- a/internal/typeutils/internaltofrontend.go +++ b/internal/typeutils/internaltofrontend.go @@ -699,8 +699,8 @@ func (c *converter) StatusToAPIStatus(ctx context.Context, s *gtsmodel.Status, r } if appID := s.CreatedWithApplicationID; appID != "" { - app := >smodel.Application{} - if err := c.db.GetByID(ctx, appID, app); err != nil { + app, err := c.db.GetApplicationByID(ctx, appID) + if err != nil { return nil, fmt.Errorf("error getting application %s: %w", appID, err) } -- cgit v1.2.3