1 import { Memoize } from '@server/helpers/memoize'
2 import { ServerModel } from '@server/models/server/server'
3 import { ActorModel } from '../../actor'
4 import { ActorFollowModel } from '../../actor-follow'
5 import { ActorImageModel } from '../../actor-image'
7 export class ActorFollowTableAttributes {
10 getFollowAttributes () {
11 return ActorFollowModel.getSQLAttributes('ActorFollowModel').join(', ')
15 getActorAttributes (actorTableName: string) {
16 return ActorModel.getSQLAttributes(actorTableName, `${actorTableName}.`).join(', ')
20 getServerAttributes (actorTableName: string) {
21 return ServerModel.getSQLAttributes(`${actorTableName}->Server`, `${actorTableName}.Server.`).join(', ')
25 getAvatarAttributes (actorTableName: string) {
26 return ActorImageModel.getSQLAttributes(`${actorTableName}->Avatars`, `${actorTableName}.Avatars.`).join(', ')