diff --git a/lib/server/handle/create-resource-url.ts b/lib/server/handle/create-resource-url.ts index 896556e6ed..e130713523 100644 --- a/lib/server/handle/create-resource-url.ts +++ b/lib/server/handle/create-resource-url.ts @@ -3,7 +3,7 @@ import { assert, createUrl } from "@acdh-oeaw/lib"; import { env } from "@/config/env.config"; export function createResourceUrl(path: string): URL { - const message = "Invalid resource path."; + const message = `Invalid resource path: ${path}`; assert(path.endsWith("/index.mdx"), message); diff --git a/scripts/handle/create-handle.sh b/scripts/handle/create-handle.sh index a99e37758c..55ac79d6e3 100644 --- a/scripts/handle/create-handle.sh +++ b/scripts/handle/create-handle.sh @@ -5,7 +5,7 @@ if [[ ${VERCEL_ENV} != "production" || ${VERCEL_GIT_COMMIT_REF} != "main" ]]; th exit 0 fi -files=$(git diff --diff-filter=AMR --name-only ${VERCEL_GIT_PREVIOUS_SHA} ${VERCEL_GIT_COMMIT_SHA} -- 'content/*/curricula/**/*.mdx' 'content/*/resources/**/*.mdx' | xargs) +files=$(git diff --diff-filter=AMR --name-only ${VERCEL_GIT_PREVIOUS_SHA} ${VERCEL_GIT_COMMIT_SHA} -- 'content/*/curricula/**/index.mdx' 'content/*/resources/**/index.mdx' | xargs) for file in $files; do echo "Processing ${file}..."