|
|
@ -65,16 +65,12 @@ class HomeController extends SiteController { |
|
|
|
async getHome (req, res, next) { |
|
|
|
const { |
|
|
|
announcement: announcementService, |
|
|
|
hive: hiveService, |
|
|
|
oauth2: oauth2Service, |
|
|
|
} = this.dtp.services; |
|
|
|
try { |
|
|
|
res.locals.announcements = await announcementService.getLatest(req.user); |
|
|
|
res.locals.featuredDestinations = await oauth2Service.getRandomClients(3); |
|
|
|
|
|
|
|
res.locals.pagination = this.getPaginationParameters(req, 20); |
|
|
|
res.locals.constellationTimeline = await hiveService.getConstellationTimeline(res.locals.pagination); |
|
|
|
|
|
|
|
res.render('index'); |
|
|
|
} catch (error) { |
|
|
|
this.log.error('failed to render home view', { error }); |
|
|
|