Skip to content

Commit 867fa38

Browse files
committed
chore: fix demo func json parsing
1 parent 690172e commit 867fa38

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

demo/func/HelloWorld/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ app.http('httpTrigger1', {
88
let name;
99
if (req.query.has('name')) {
1010
name = req.query.get('name');
11-
} else {
11+
} else if (req.headers.get('content-type') === 'application/json') {
1212
let body = await req.json();
1313
name = body.name;
1414
}

0 commit comments

Comments
 (0)