Skip to content

Commit

Permalink
Fix payload init issue (rgstephens#44)
Browse files Browse the repository at this point in the history
* fix payload init

* update version
  • Loading branch information
rgstephens committed Jan 3, 2023
1 parent 3a1e1f0 commit 4efc82e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
23 changes: 12 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,19 @@ A NodeRed node to execute GraphQL Queries.

## Change Log

| Vers | Changes |
| ----- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 2.1.0 | Bearer Token Authentication |
| 2.0.1 | Update dependencies (`axios` & `mustache`), fix node-red scorecard issues |
| 2.0.0 | GraphQL response is now on `payload.graphql` instead of replacing `payload`. This is a breaking change. Addresses #32 |
| 1.4.1 | Bump `follow-redirects` to 1.14.8 |
| 1.4.0 | improve debug, bump `follow-redirects` |
| 1.3.0 | bump axios to address CVE-2021-3749 |
| 1.2.0 | [Fix node not showing in palette](https://github.com/rgstephens/node-red-contrib-graphql/pull/24), bump axios |
| Vers | Changes |
| ----- | -------------------------------------------------------- |
| 2.1.1 | Fix payload init issue |
| 2.1.0 | Bearer Token Authentication |
| 2.0.1 | Update dependencies (`axios` & `mustache`), fix node-red scorecard issues |
| 2.0.0 | GraphQL response is now on `payload.graphql` instead of replacing `payload`. This is a breaking change. Addresses #32 |
| 1.4.1 | Bump `follow-redirects` to 1.14.8 |
| 1.4.0 | improve debug, bump `follow-redirects` |
| 1.3.0 | bump axios to address CVE-2021-3749 |
| 1.2.0 | [Fix node not showing in palette](https://github.com/rgstephens/node-red-contrib-graphql/pull/24), bump axios |
| 1.1.0 | [Error Handling & Config Templates](https://github.com/rgstephens/node-red-contrib-graphql/pull/11/), [showDebug & customHeaders](https://github.com/rgstephens/node-red-contrib-graphql/pull/22/conflicts), [Bump axios](https://github.com/rgstephens/node-red-contrib-graphql/pull/20) |
| 1.0.0 | pass Authorization via msg.authorization, [PR #21](https://github.com/rgstephens/node-red-contrib-graphql/pull/21) |
| 0.0.6 | Initial Release |
| 1.0.0 | pass Authorization via msg.authorization, [PR #21](https://github.com/rgstephens/node-red-contrib-graphql/pull/21)|
| 0.0.6 | Initial Release |

## GraphQL Nodes

Expand Down
3 changes: 1 addition & 2 deletions graphql.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module.exports = function(RED) {
var axios = require("axios");
var mustache = require("mustache");

var vers = "2.1.0";
var vers = "2.1.1";

function isReadable(value) {
return typeof value === 'object' && typeof value._read === 'function' && typeof value._readableState === 'object'
Expand Down Expand Up @@ -151,7 +151,6 @@ module.exports = function(RED) {
shape: "dot",
text: RED._("graphql.status.success")
});
node.msg.payload = {}
node.msg.payload.graphql = response.data.data; // remove .data to see entire response
if (node.showDebug){
node.msg.debugInfo = {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "node-red-contrib-graphql",
"version": "2.1.0",
"version": "2.1.1",
"description": "A Node-RED node to make GraphQL calls",
"dependencies": {
"axios": "~1.2.1",
Expand Down

0 comments on commit 4efc82e

Please sign in to comment.