Fix repeating Home feeds with timestamp cursors across local and swarm sources, remote profile pagination, duplicate filtering, and in-flight request guards.

Hop-State: A_06FPACHVKP3PTEY7DT6NW1R
Hop-Proposal: R_06FPACGSH34JXPKH7QHAXAR
Hop-Task: T_06FPABDPSJFCRPZSG0PXS9G
Hop-Attempt: AT_06FPABDPSG9CRMFEZ4WC35R
This commit is contained in:
2026-07-15 02:53:38 -07:00
committed by Hop
parent a7a430a627
commit 93be1cffd8
6 changed files with 93 additions and 11 deletions
+3 -2
View File
@@ -396,7 +396,8 @@ export interface SwarmProfileResponse {
export async function fetchSwarmUserProfile(
handle: string,
domain: string,
postsLimit: number = 25
postsLimit: number = 25,
cursor?: string
): Promise<SwarmProfileResponse | null> {
try {
const normalizedDomain = normalizeNodeDomain(domain);
@@ -410,7 +411,7 @@ export async function fetchSwarmUserProfile(
? `http://${normalizedDomain}`
: `https://${normalizedDomain}`;
const url = `${baseUrl}/api/swarm/users/${handle}?limit=${postsLimit}`;
const url = `${baseUrl}/api/swarm/users/${handle}?limit=${postsLimit}${cursor ? `&cursor=${encodeURIComponent(cursor)}` : ''}`;
const controller = new AbortController();
const timeout = setTimeout(() => controller.abort(), 10000);