Skip to content

Commit

Permalink
fix: typo
Browse files Browse the repository at this point in the history
  • Loading branch information
farnabaz committed Dec 5, 2022
1 parent 4ab5e05 commit a7912af
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/module.ts
Expand Up @@ -561,7 +561,7 @@ export default defineNuxtModule<ModuleOptions>({

contentContext.defaultLocale = contentContext.defaultLocale || contentContext.locales[0]

// Generate cache integerity based on content context
// Generate cache integrity based on content context
const cacheIntegrity = hash({
locales: options.locales,
options: options.defaultLocale,
Expand Down
3 changes: 2 additions & 1 deletion src/runtime/composables/navigation.ts
Expand Up @@ -10,7 +10,8 @@ export const fetchContentNavigation = async (queryBuilder?: QueryBuilder | Query
// When params is an instance of QueryBuilder then we need to pick the params explicitly
const params: QueryBuilderParams = typeof queryBuilder?.params === 'function' ? queryBuilder.params() : queryBuilder

const apiPath = withContentBase(params ? `/navigation/${hash(params)}.${content.integerity}.json` : '/navigation')
const _apiPath = params ? `/navigation/${hash(params)}` : '/navigation/'
const apiPath = withContentBase(process.dev ? _apiPath : `${_apiPath}.${content.integrity}.json`)

// Add `prefetch` to `<head>` in production
if (!process.dev && process.server) {
Expand Down
2 changes: 1 addition & 1 deletion src/runtime/composables/query.ts
Expand Up @@ -27,7 +27,7 @@ export const createQueryFetch = <T = ParsedContent>(path?: string) => async (que

const params = query.params()

const apiPath = withContentBase(process.dev ? '/query' : `/query/${hash(params)}.${content.integerity}.json`)
const apiPath = withContentBase(process.dev ? '/query' : `/query/${hash(params)}.${content.integrity}.json`)

// Prefetch the query
if (!process.dev && process.server) {
Expand Down

0 comments on commit a7912af

Please sign in to comment.