Add story to endpoint list

This commit is contained in:
Sam Carlton 2021-03-13 20:55:43 -06:00
parent 8d49abdbad
commit f7968acbb6

View file

@ -9,7 +9,7 @@ import buildVideoList from './helpers/build-video-list.js'
import { buildVideoPayload, buildAppBenchmarkPayload } from './helpers/build-payload.js'
import { categories, getAppCategory } from './helpers/categories.js'
import { getAppType, getAppEndpoint, getVideoEndpoint } from './helpers/app-derived.js'
import { hasStory, getAppType, getAppEndpoint, getVideoEndpoint } from './helpers/app-derived.js'
import { makeSearchableList } from './helpers/searchable-list.js'
// Setup dotenv
@ -236,6 +236,14 @@ class BuildLists {
// if ( isGame ) { console.log() }
// Add story endpoints for native apps
if ( hasStory( app ) ) {
const payload = buildAppBenchmarkPayload( app, this.allVideoAppsList, this.lists.video )
this.endpointMaps.nuxt.set( `${getAppEndpoint(app)}/story/`, payload )
}
// Add benchmark endpoints for apps and games
if ( appType === 'app' || appType === 'game' ) {
const payload = buildAppBenchmarkPayload( app, this.allVideoAppsList, this.lists.video )