File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -97,7 +97,16 @@ export default defineNuxtModule<VueFireNuxtModuleOptions>({
9797 // plugins
9898
9999 if ( options . appCheck ) {
100- if ( process . env . FIREBASE_APPCHECK_DEBUG_TOKEN ) {
100+ if (
101+ process . env . FIREBASE_APPCHECK_DEBUG_TOKEN &&
102+ // only use the debug token if the user explicitly set debug to true or if nothing was provided and we are not in production
103+ ( options . appCheck . debug === true ||
104+ ( options . appCheck . debug == null &&
105+ process . env . NODE_ENV !== 'production' ) )
106+ ) {
107+ logger . debug (
108+ `Using app check debug token from env variable "${ process . env . FIREBASE_APPCHECK_DEBUG_TOKEN } "`
109+ )
101110 options . appCheck . debug = process . env . FIREBASE_APPCHECK_DEBUG_TOKEN
102111 }
103112 addPlugin ( resolve ( runtimeDir , 'app-check/plugin.client' ) )
You can’t perform that action at this time.
0 commit comments