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:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user