Skip to content

Commit 7b2c8d2

Browse files
committed
test: upload test case in order to test on staging env
1 parent 2fb25ea commit 7b2c8d2

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

demos/default/pages/getStaticProps/with-revalidate-404.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,15 @@ const Show = () => (
1111
)
1212

1313
export async function getStaticProps(context) {
14+
const time = new Date().getMinutes() % 10 < 5
15+
// return {
16+
// redirect: time ? { destination: '/404', permanent: false} : undefined
17+
// }
18+
1419
return {
1520
props: {},
16-
notFound: new Date().getMinutes() % 10 < 5,
21+
// notFound: new Date().getMinutes() % 10 < 5,
22+
redirect: time ? { destination: '/404', permanent: true} : undefined,
1723
revalidate: 60,
1824
}
1925
}

0 commit comments

Comments
 (0)