From ae5402ada6aa794a69de455f745934b27e030d3d Mon Sep 17 00:00:00 2001 From: tobi <31960611+tsmethurst@users.noreply.github.com> Date: Sat, 28 May 2022 19:59:55 +0200 Subject: [chore] Mastodon api fixups (#617) * don't omitempty on description * don't omitempty on any fields * add ms to timestamp format * don't omitempty on text_url * rearrange attachment fields a bit * just give URL again as attachment text url * update tests * fix accidental replace --- internal/typeutils/internaltofrontend.go | 1 + 1 file changed, 1 insertion(+) (limited to 'internal/typeutils/internaltofrontend.go') diff --git a/internal/typeutils/internaltofrontend.go b/internal/typeutils/internaltofrontend.go index 9601f3e3a..8ad601f0c 100644 --- a/internal/typeutils/internaltofrontend.go +++ b/internal/typeutils/internaltofrontend.go @@ -238,6 +238,7 @@ func (c *converter) AttachmentToAPIAttachment(ctx context.Context, a *gtsmodel.M ID: a.ID, Type: strings.ToLower(string(a.Type)), URL: a.URL, + TextURL: a.URL, PreviewURL: a.Thumbnail.URL, RemoteURL: a.RemoteURL, PreviewRemoteURL: a.Thumbnail.RemoteURL, -- cgit v1.2.3