Я обновил свой модуль firebase-functions до 3.0.1. Теперь, когда я развертываю облачные функции, я получаю предупреждающее сообщение:
⚠ функции: развертывание функций в среде выполнения Node 6, которая устарела. Узел 8 доступен и является рекомендуемой средой выполнения.
Затем развертывание завершается ошибкой:
Function failed on loading user code. Error message: Code in file lib/index.js can't be loaded.
Is there a syntax error in your code?
Detailed stack trace: /user_code/node_modules/firebase-functions/lib/providers/https.js:282
const func = async (req, res) => {
^
SyntaxError: Unexpected token (
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:549:28)
at Object.Module._extensions..js (module.js:586:10)
at Module.load (module.js:494:32)
at tryModuleLoad (module.js:453:12)
at Function.Module._load (module.js:445:3)
at Module.require (module.js:504:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/user_code/node_modules/firebase-functions/lib/index.js:39:15)
Как я могу это исправить?