summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarie <github@yuugi.dev>2025-02-17 19:47:36 +0000
committerMarie <github@yuugi.dev>2025-02-17 19:47:36 +0000
commit3dfd018305cc9a315de4c5c6e7f4cc8247ca73b0 (patch)
treea144c8494af0d2a65998a82d702cd34ac2c3ae7c
parentmerge: Increase rate limit on server-info to avoid errors and blank graphs (!... (diff)
parentfix error message when a peertube object is reject for bad ID / URL (diff)
downloadsharkey-3dfd018305cc9a315de4c5c6e7f4cc8247ca73b0.tar.gz
sharkey-3dfd018305cc9a315de4c5c6e7f4cc8247ca73b0.tar.bz2
sharkey-3dfd018305cc9a315de4c5c6e7f4cc8247ca73b0.zip
merge: Fix error message when a peertube object is rejected for bad ID / URL (!900)
View MR for information: https://activitypub.software/TransFem-org/Sharkey/-/merge_requests/900 Approved-by: dakkar <dakkar@thenautilus.net> Approved-by: Marie <github@yuugi.dev>
-rw-r--r--packages/backend/src/core/activitypub/misc/check-against-url.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/backend/src/core/activitypub/misc/check-against-url.ts b/packages/backend/src/core/activitypub/misc/check-against-url.ts
index edfab5a216..0c676c6a29 100644
--- a/packages/backend/src/core/activitypub/misc/check-against-url.ts
+++ b/packages/backend/src/core/activitypub/misc/check-against-url.ts
@@ -26,6 +26,6 @@ export function assertActivityMatchesUrls(activity: IObject, urls: string[]) {
.map(u => new URL(u as string).href);
if (!actualUrls.some(u => expectedUrls.has(u))) {
- throw new UnrecoverableError(`bad Activity: neither id(${activity.id}) nor url(${JSON.stringify(activity.url)}) match location(${urls})`);
+ throw new UnrecoverableError(`bad Activity: neither id nor url (${actualUrls.join(', ')}) match location (${urls.join(', ')})`);
}
}