diff --git a/src/logger.ts b/src/logger.ts index 4d6052a..132f4ad 100644 --- a/src/logger.ts +++ b/src/logger.ts @@ -1,3 +1,4 @@ import { useLogger } from '@nuxt/kit' +import type { ConsolaInstance } from 'consola' -export const logger = useLogger('@nuxt/fonts') +export const logger: ConsolaInstance = useLogger('@nuxt/fonts') diff --git a/src/module.ts b/src/module.ts index e661b6a..a5d755c 100644 --- a/src/module.ts +++ b/src/module.ts @@ -187,7 +187,8 @@ export default defineNuxtModule({ // Rewrite font source URLs to be proxied/local URLs const fonts = normalizeFontData(result?.fonts || []) if (!fonts.length || !result) { - return logger.warn(`Could not produce font face declaration from \`${override.provider}\` for font family \`${fontFamily}\`.`) + logger.warn(`Could not produce font face declaration from \`${override.provider}\` for font family \`${fontFamily}\`.`) + return } exposeFont({ type: 'override',