ActivityPub-federated video streaming platform using P2P directly in your web browser
Fix deleting not found remote actors
Chocobozzz699b059e2d6c
diff --git a/server/lib/activitypub/actor.ts b/server/lib/activitypub/actor.tsindex d728c81d19..edf38bc0a5 100644--- a/server/lib/activitypub/actor.ts+++ b/server/lib/activitypub/actor.ts@@ -211,7 +211,14 @@ async function refreshActorIfNeeded (const actor = fetchedType === 'all' ? actorArg : await ActorModel.loadByUrlAndPopulateAccountAndChannel(actorArg.url)try {- const actorUrl = await getUrlFromWebfinger(actor.preferredUsername + '@' + actor.getHost())+ let actorUrl: string+ try {+ actorUrl = await getUrlFromWebfinger(actor.preferredUsername + '@' + actor.getHost())+ } catch (err) {+ logger.warn('Cannot get actor URL from webfinger, keeping the old one.', err)+ actorUrl = actor.url+ }+const { result, statusCode } = await fetchRemoteActor(actorUrl)if (statusCode === 404) {@@ -429,5 +436,3 @@ async function saveVideoChannel (actor: ActorModel, result: FetchRemoteActorResureturn videoChannelCreated}--