summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar tobi <31960611+tsmethurst@users.noreply.github.com>2024-09-29 14:46:52 +0200
committerLibravatar GitHub <noreply@github.com>2024-09-29 14:46:52 +0200
commit43e443f9f3a2c5adaea38fa9267c41d42fa33d58 (patch)
treefa6ab9ab34d7c4bb1e46d2ee5f51021cf40ca392
parent[bugfix] visibility after implicit approval not getting invalidated (#3370) (diff)
downloadgotosocial-43e443f9f3a2c5adaea38fa9267c41d42fa33d58.tar.xz
[bugfix] Carry-over "PinnedAt" when refreshing status (#3373)
-rw-r--r--internal/federation/dereferencing/status.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/internal/federation/dereferencing/status.go b/internal/federation/dereferencing/status.go
index 28e9d0196..8ca5418f2 100644
--- a/internal/federation/dereferencing/status.go
+++ b/internal/federation/dereferencing/status.go
@@ -516,10 +516,12 @@ func (d *Dereferencer) enrichStatus(
latestStatus.ID = status.ID
}
- // Carry-over values and set fetch time.
- latestStatus.UpdatedAt = status.UpdatedAt
+ // Set latest fetch time and carry-
+ // over some values from "old" status.
latestStatus.FetchedAt = time.Now()
+ latestStatus.UpdatedAt = status.UpdatedAt
latestStatus.Local = status.Local
+ latestStatus.PinnedAt = status.PinnedAt
// Carry-over approvals. Remote instances might not yet
// serve statuses with the `approved_by` field, but we