From 5cabd11dfbdee738692decf8578fd243310948cb Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 13 Mar 2024 22:55:04 +0530 Subject: [PATCH] build(deps): update dependency @nuxt/content to v2.12.1 (#198) * build(deps): update dependency @nuxt/content to v2.12.1 * fix(article): use null check instead of accessing private attributes --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Arunanshu Biswas --- package.json | 2 +- pnpm-lock.yaml | 14 +++++++------- src/pages/info/[article].vue | 3 +-- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/package.json b/package.json index fade5b5..43825ed 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,7 @@ "vue-tsc": "^2.0.0" }, "dependencies": { - "@nuxt/content": "2.12.0", + "@nuxt/content": "2.12.1", "@nuxt/image": "^1.3.0", "@nuxtjs/critters": "^0.6.0", "@nuxtjs/fontaine": "^0.4.1", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ea775f8..a26bca0 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -6,8 +6,8 @@ settings: dependencies: '@nuxt/content': - specifier: 2.12.0 - version: 2.12.0(@planetscale/database@1.16.0)(nuxt@3.10.3)(vue@3.4.21) + specifier: 2.12.1 + version: 2.12.1(@planetscale/database@1.16.0)(nuxt@3.10.3)(vue@3.4.21) '@nuxt/image': specifier: ^1.3.0 version: 1.4.0(@planetscale/database@1.16.0) @@ -1778,11 +1778,11 @@ packages: - bluebird - supports-color - /@nuxt/content@2.12.0(@planetscale/database@1.16.0)(nuxt@3.10.3)(vue@3.4.21): - resolution: {integrity: sha512-XQkbkJzFRWKdX4aoVDprqLphbQGDsRX35ZRgHe4i7Phe3F1z2EzXVhZ9WXBTmpXau3MkLlmsQ+NzcRns1kOOvQ==} + /@nuxt/content@2.12.1(@planetscale/database@1.16.0)(nuxt@3.10.3)(vue@3.4.21): + resolution: {integrity: sha512-xW4xjyYm6zqglb17Tu0J+rpKUV1PF9zp6SLu1lopylFnerdyImtce84206HT6Zd/DJgivKtoW4dyyJn0ZaSqCQ==} dependencies: '@nuxt/kit': 3.10.3 - '@nuxtjs/mdc': 0.5.0 + '@nuxtjs/mdc': 0.6.1 '@vueuse/core': 10.9.0(vue@3.4.21) '@vueuse/head': 2.0.0(vue@3.4.21) '@vueuse/nuxt': 10.9.0(nuxt@3.10.3)(vue@3.4.21) @@ -2166,8 +2166,8 @@ packages: - supports-color dev: false - /@nuxtjs/mdc@0.5.0: - resolution: {integrity: sha512-480Ajc7o/YAl9b21btd0oRtVe/UjUWmVSEWauS+H+izwEGdGvJTVfZRdaiAXcXKl+UmUTpf+POel027sE9HAZQ==} + /@nuxtjs/mdc@0.6.1: + resolution: {integrity: sha512-zS5QK7DZ/SBrjqQX1DOy7GnxKy+wbj2+LvooefOWmQqHfLTAqJLVIjuv/BmKnQWiRCq19+uysys3iY42EoY5/A==} dependencies: '@nuxt/kit': 3.10.3 '@shikijs/transformers': 1.1.7 diff --git a/src/pages/info/[article].vue b/src/pages/info/[article].vue index c766fbd..587b829 100644 --- a/src/pages/info/[article].vue +++ b/src/pages/info/[article].vue @@ -16,11 +16,10 @@ const { data, error } = await useAsyncData(path, () => { return queryContent(path).only(['title', 'body']).findOne() }) -if (error.value || data.value?._empty) { +if (error.value || !data.value) { throw createError({ statusCode: 404, statusMessage: 'The page you are looking for does not exist.', - fatal: true, }) }