diff --git a/pages/tech-and-disability.js b/pages/tech-and-disability.js index be1239d..e82f506 100755 --- a/pages/tech-and-disability.js +++ b/pages/tech-and-disability.js @@ -9,9 +9,9 @@ import Head from 'next/head' export async function getServerSideProps(context) { if(context.query.page == null || context.query.page == '0') { - var page = 0; + var page = 1; } else { - var page = Number(context.query.page) - 1 + var page = Number(context.query.page) } const { serverRuntimeConfig, publicRuntimeConfig } = getConfig() @@ -20,7 +20,7 @@ export async function getServerSideProps(context) { const rssFeed = config.siteURL+"/feed/"+project.data[0].attributes.Slug+"-feed.xml" - const articles = await getAllPosts([project.data[0].attributes.Slug], page, 5) + const articles = await getAllPosts(project.data[0].attributes.Slug, page, 5) const secres = await fetch(serverRuntimeConfig.base_path + `/api/sections`) const secdata = await secres.json()