mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Handle numberic msg.payload in HTTP Response node
This commit is contained in:
parent
958de21be8
commit
b78210e3be
@ -293,6 +293,9 @@ module.exports = function(RED) {
|
|||||||
msg.res._res.set('content-length', len);
|
msg.res._res.set('content-length', len);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (typeof msg.payload === "number") {
|
||||||
|
msg.payload = ""+msg.payload;
|
||||||
|
}
|
||||||
msg.res._res.status(statusCode).send(msg.payload);
|
msg.res._res.status(statusCode).send(msg.payload);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user