X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Flib%2Factivitypub%2Factor.ts;h=04296864b96c88038ed4726ca166679a10558550;hb=5224c394b3bbac6ec1543e41fa0ec6db436e84fa;hp=38eb87d1e917b351a5dc7df983092f1cf275e8be;hpb=b91bc1d1f3591c35ab4426f6ab594b4bd9f1ef62;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/lib/activitypub/actor.ts b/server/lib/activitypub/actor.ts index 38eb87d1e..04296864b 100644 --- a/server/lib/activitypub/actor.ts +++ b/server/lib/activitypub/actor.ts @@ -195,7 +195,7 @@ async function fetchAvatarIfExists (actorJSON: ActivityPubActor) { return undefined } -async function addFetchOutboxJob (actor: ActorModel) { +async function addFetchOutboxJob (actor: Pick) { // Don't fetch ourselves const serverActor = await getServerActor() if (serverActor.id === actor.id) { @@ -254,14 +254,14 @@ async function refreshActorIfNeeded ( await actor.save({ transaction: t }) if (actor.Account) { - actor.Account.set('name', result.name) - actor.Account.set('description', result.summary) + actor.Account.name = result.name + actor.Account.description = result.summary await actor.Account.save({ transaction: t }) } else if (actor.VideoChannel) { - actor.VideoChannel.set('name', result.name) - actor.VideoChannel.set('description', result.summary) - actor.VideoChannel.set('support', result.support) + actor.VideoChannel.name = result.name + actor.VideoChannel.description = result.summary + actor.VideoChannel.support = result.support await actor.VideoChannel.save({ transaction: t }) }