Skip to content

Commit d589d78

Browse files
committed
Fix template.
1 parent f766f50 commit d589d78

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

functions/helloworld/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,12 +150,13 @@ exports.helloError3 = function helloError3 (event, callback) {
150150
/* eslint-enable */
151151

152152
// [START functions_helloworld_template]
153+
const path = require('path');
153154
const pug = require('pug');
154155

155156
// Renders the index.pug
156157
exports.helloTemplate = (req, res) => {
157158
// Render the index.pug file
158-
const html = pug.renderFile('./index.pug');
159+
const html = pug.renderFile(path.join(__dirname, 'index.pug'));
159160

160161
res.send(html).end();
161162
};

0 commit comments

Comments
 (0)