From 458f25d6ab65edb7c76e920f39afcbd2bd11c746 Mon Sep 17 00:00:00 2001 From: Lauren Long Date: Tue, 31 Jul 2018 20:26:19 -0700 Subject: [PATCH] Update Node.js version warning message (#261) --- bin/functions | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/functions b/bin/functions index 0d85c92..5830391 100755 --- a/bin/functions +++ b/bin/functions @@ -26,8 +26,9 @@ if (!semver.satisfies(process.version, '>= 6.11.5')) { process.exit(1); } -if (semver.satisfies(process.version, '>= 7.0.0')) { - console.log(`Warning: You're using Node.js ${process.version} but Google Cloud Functions only supports v6.11.5.`); +if (semver.satisfies(process.version, '7.x.x') || semver.satisfies(process.version, '>= 9.0.0')) { + console.log(`Warning: You're using Node.js ${process.version} but the Google Cloud Functions runtime is only available in Node.js 6 and Node.js 8.` + + ` Therefore, results from running emulated functions may not match production behavior.`); } /**