update person model
This commit is contained in:
parent
2051bec543
commit
ef707b01bc
|
@ -172,7 +172,7 @@ export async function createPerson(uri: string, resolver?: Resolver): Promise<Us
|
||||||
lastFetchedAt: new Date(),
|
lastFetchedAt: new Date(),
|
||||||
name: truncate(person.name, nameLength),
|
name: truncate(person.name, nameLength),
|
||||||
isLocked: !!person.manuallyApprovesFollowers,
|
isLocked: !!person.manuallyApprovesFollowers,
|
||||||
movedToUri: person.movedToUri,
|
movedToUri: person.movedTo,
|
||||||
alsoKnownAs: person.alsoKnownAs,
|
alsoKnownAs: person.alsoKnownAs,
|
||||||
isExplorable: !!person.discoverable,
|
isExplorable: !!person.discoverable,
|
||||||
username: person.preferredUsername,
|
username: person.preferredUsername,
|
||||||
|
@ -345,7 +345,7 @@ export async function updatePerson(uri: string, resolver?: Resolver | null, hint
|
||||||
isBot: getApType(object) === 'Service',
|
isBot: getApType(object) === 'Service',
|
||||||
isCat: (person as any).isCat === true,
|
isCat: (person as any).isCat === true,
|
||||||
isLocked: !!person.manuallyApprovesFollowers,
|
isLocked: !!person.manuallyApprovesFollowers,
|
||||||
movedToUri: person.movedToUri,
|
movedToUri: person.movedTo,
|
||||||
alsoKnownAs: person.alsoKnownAs,
|
alsoKnownAs: person.alsoKnownAs,
|
||||||
isExplorable: !!person.discoverable,
|
isExplorable: !!person.discoverable,
|
||||||
} as Partial<User>;
|
} as Partial<User>;
|
||||||
|
|
|
@ -156,7 +156,7 @@ export interface IActor extends IObject {
|
||||||
name?: string;
|
name?: string;
|
||||||
preferredUsername?: string;
|
preferredUsername?: string;
|
||||||
manuallyApprovesFollowers?: boolean;
|
manuallyApprovesFollowers?: boolean;
|
||||||
movedToUri?: string;
|
movedTo?: string;
|
||||||
alsoKnownAs?: string[];
|
alsoKnownAs?: string[];
|
||||||
discoverable?: boolean;
|
discoverable?: boolean;
|
||||||
inbox: string;
|
inbox: string;
|
||||||
|
|
Loading…
Reference in New Issue