collective page fix

This commit is contained in:
tmshv committed 2020-02-19 00:01:06 +03:00
1 parent 29c2a53c54
commit 07cb773c6f
1 file changed
+2 -2
+2 -2
View File
@@ -71,8 +71,8 @@ export const unstable_getStaticProps = async (ctx: NextPageContext) => {
// const pageUrl = ctx.req.url
const pageUrl = '/collective'
const res = await requestGet<IResponseItems<IPerson>>(createApiUrl('/api/persons'), { items: [] })
const data = res.items || []
const res = await requestGet<IResponseItems<IPerson>>(createApiUrl('/api/persons'), null)
const data = res?.items || []
const title = 'Преподаватели Шлиссельбургской ДХШ'
const imageFile = 'Images/HudozkaCollective2017.jpg'
const resImage = await requestGet(createApiUrl(`/api/image?file=${imageFile}`), null)