diff --git a/pages/blog/[single].jsx b/pages/blog/[single].jsx index 20fbdef..b1b454e 100644 --- a/pages/blog/[single].jsx +++ b/pages/blog/[single].jsx @@ -114,7 +114,7 @@ export async function getStaticProps({ params }) { .get( /** ********************* Get Options object */ { - host: "datasquirel.tben.me", + host: "datasquirel.com", path: `/api/query/get?db=tbenme&query=select+*+from+blog_posts+where+slug='${params.single}'`, headers: { Authorization: process.env.DATASQUIREL_API_KEY, @@ -200,7 +200,7 @@ export async function getStaticPaths() { .get( /** ********************* Get Options object */ { - host: "datasquirel.tben.me", + host: "datasquirel.com", path: `/api/query/get?db=tbenme&query=select+slug+from+blog_posts`, headers: { Authorization: process.env.DATASQUIREL_API_KEY, diff --git a/pages/blog/index.jsx b/pages/blog/index.jsx index e0f50ce..10d02c4 100644 --- a/pages/blog/index.jsx +++ b/pages/blog/index.jsx @@ -140,7 +140,7 @@ export async function getStaticProps({ req, res, query }) { .get( /** ********************* Get Options object */ { - host: "datasquirel.tben.me", + host: "datasquirel.com", path: `/api/query/get?db=tbenme&query=select+title,slug,excerpt,date_created+from+blog_posts+limit+10`, headers: { Authorization: process.env.DATASQUIREL_API_KEY, @@ -172,6 +172,10 @@ export async function getStaticProps({ req, res, query }) { .end(); }); + console.log('===================================='); + console.log(postsResponse); + console.log('===================================='); + if (!postsResponse.success) { return { redirect: {