云函数调用startTransaction()启用数据库事务,部署后调用失败的原因?
云函数调用startTransaction()引用数据库事务,安装"wx-server-sdk": "^1.7.0,云函数本地调试可以成功调用。
但上传并部署(所有文件)调用则报错,请问什么原因?
{“errorCode”:1,“errorMessage”:“user code exception caught”,“stackTrace”:“transaction is not defined\nReferenceError: transaction is not defined\n at EventHandler.exports.main [as realHandler] (/var/user/index.js:92:5)\n at \u003canonymous\u003e\n at process._tickCallback (internal/process/next_tick.js:188:7)”}