aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/activitypub/actor.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/models/activitypub/actor.ts')
-rw-r--r--server/models/activitypub/actor.ts9
1 files changed, 2 insertions, 7 deletions
diff --git a/server/models/activitypub/actor.ts b/server/models/activitypub/actor.ts
index 2fceb21dd..7d91e8a4a 100644
--- a/server/models/activitypub/actor.ts
+++ b/server/models/activitypub/actor.ts
@@ -34,7 +34,7 @@ import { ACTIVITY_PUB, ACTIVITY_PUB_ACTOR_TYPES, CONFIG, CONSTRAINTS_FIELDS } fr
34import { AccountModel } from '../account/account' 34import { AccountModel } from '../account/account'
35import { AvatarModel } from '../avatar/avatar' 35import { AvatarModel } from '../avatar/avatar'
36import { ServerModel } from '../server/server' 36import { ServerModel } from '../server/server'
37import { throwIfNotValid } from '../utils' 37import { isOutdated, throwIfNotValid } from '../utils'
38import { VideoChannelModel } from '../video/video-channel' 38import { VideoChannelModel } from '../video/video-channel'
39import { ActorFollowModel } from './actor-follow' 39import { ActorFollowModel } from './actor-follow'
40import { VideoModel } from '../video/video' 40import { VideoModel } from '../video/video'
@@ -532,11 +532,6 @@ export class ActorModel extends Model<ActorModel> {
532 isOutdated () { 532 isOutdated () {
533 if (this.isOwned()) return false 533 if (this.isOwned()) return false
534 534
535 const now = Date.now() 535 return isOutdated(this, ACTIVITY_PUB.ACTOR_REFRESH_INTERVAL)
536 const createdAtTime = this.createdAt.getTime()
537 const updatedAtTime = this.updatedAt.getTime()
538
539 return (now - createdAtTime) > ACTIVITY_PUB.ACTOR_REFRESH_INTERVAL &&
540 (now - updatedAtTime) > ACTIVITY_PUB.ACTOR_REFRESH_INTERVAL
541 } 536 }
542} 537}