aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/webfinger.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/controllers/webfinger.ts')
-rw-r--r--server/controllers/webfinger.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/server/controllers/webfinger.ts b/server/controllers/webfinger.ts
index 8829500bc..ed781c21b 100644
--- a/server/controllers/webfinger.ts
+++ b/server/controllers/webfinger.ts
@@ -1,7 +1,7 @@
1import * as express from 'express' 1import * as express from 'express'
2import { asyncMiddleware } from '../middlewares' 2import { asyncMiddleware } from '../middlewares'
3import { webfingerValidator } from '../middlewares/validators' 3import { webfingerValidator } from '../middlewares/validators'
4import { AccountModel } from '../models/account/account' 4import { ActorModel } from '../models/activitypub/actor'
5 5
6const webfingerRouter = express.Router() 6const webfingerRouter = express.Router()
7 7
@@ -19,16 +19,16 @@ export {
19// --------------------------------------------------------------------------- 19// ---------------------------------------------------------------------------
20 20
21function webfingerController (req: express.Request, res: express.Response, next: express.NextFunction) { 21function webfingerController (req: express.Request, res: express.Response, next: express.NextFunction) {
22 const account = res.locals.account as AccountModel 22 const actor = res.locals.actor as ActorModel
23 23
24 const json = { 24 const json = {
25 subject: req.query.resource, 25 subject: req.query.resource,
26 aliases: [ account.Actor.url ], 26 aliases: [ actor.url ],
27 links: [ 27 links: [
28 { 28 {
29 rel: 'self', 29 rel: 'self',
30 type: 'application/activity+json', 30 type: 'application/activity+json',
31 href: account.Actor.url 31 href: actor.url
32 } 32 }
33 ] 33 ]
34 } 34 }