diff --git a/src/js/helpers.js b/src/js/helpers.js index e1e756b4f..3015db8b2 100644 --- a/src/js/helpers.js +++ b/src/js/helpers.js @@ -97,7 +97,8 @@ export const chromeAITextGeneration = async ( prompt = '', content = '' ) => { return result; } - const supportsTextGeneration = await window.ai.languageModel.capabilities(); + const supportsTextGeneration = + await window.ai.languageModel?.capabilities(); if ( supportsTextGeneration &&