Socket
Socket
Sign inDemoInstall

graphile-build-pg

Package Overview
Dependencies
Maintainers
1
Versions
211
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

graphile-build-pg - npm Package Compare versions

Comparing version 4.0.0-rc.3 to 4.0.0-rc.4

9

node8plus/plugins/PgAllRows.js

@@ -32,3 +32,6 @@ "use strict";

} = build;
const { fieldWithHooks, scope: { isRootQuery } } = context;
const {
fieldWithHooks,
scope: { isRootQuery }
} = context;
if (!isRootQuery) {

@@ -95,3 +98,5 @@ return fields;

if (isConnection) {
const { rows: [row] } = result;
const {
rows: [row]
} = result;
return addStartEndCursor(row);

@@ -98,0 +103,0 @@ } else {

@@ -12,4 +12,8 @@ "use strict";

builder.hook("GraphQLObjectType:fields:field:args", (args, build, context) => {
const { extend, getTypeByName, graphql: { GraphQLInt } } = build;
const {
extend,
getTypeByName,
graphql: { GraphQLInt }
} = build;
const {
scope: {

@@ -16,0 +20,0 @@ isPgFieldConnection,

@@ -9,4 +9,8 @@ "use strict";

builder.hook("GraphQLObjectType:fields", (fields, build, context) => {
const { extend, inflection, graphql: { GraphQLInt } } = build;
const {
extend,
inflection,
graphql: { GraphQLInt }
} = build;
const {
scope: { isPgRowConnectionType, pgIntrospection: table },

@@ -13,0 +17,0 @@ fieldWithHooks,

@@ -41,3 +41,6 @@ "use strict";

} = build;
const { scope: { isRootMutation }, fieldWithHooks } = context;
const {
scope: { isRootMutation },
fieldWithHooks
} = context;
if (!isRootMutation) {

@@ -44,0 +47,0 @@ return fields;

@@ -17,3 +17,6 @@ "use strict";

} = build;
const { scope: { isRootMutation }, fieldWithHooks } = context;
const {
scope: { isRootMutation },
fieldWithHooks
} = context;
if (!isRootMutation) {

@@ -20,0 +23,0 @@ return fields;

@@ -48,3 +48,6 @@ "use strict";

} = build;
const { scope: { isRootMutation }, fieldWithHooks } = context;
const {
scope: { isRootMutation },
fieldWithHooks
} = context;
const { pluralize, singularize, camelCase } = inflection;

@@ -51,0 +54,0 @@ if (!isRootMutation) {

@@ -9,4 +9,7 @@ "use strict";

builder.hook("GraphQLObjectType", (object, build, context) => {
const { setNodeAlias, inflection: { pluralize } } = build;
const {
setNodeAlias,
inflection: { pluralize }
} = build;
const {
scope: { isPgRowType, isPgCompoundType, pgIntrospection: table }

@@ -13,0 +16,0 @@ } = context;

@@ -16,3 +16,5 @@ "use strict";

} = build;
const { scope: { isPgRowSortEnum, pgIntrospection: table } } = context;
const {
scope: { isPgRowSortEnum, pgIntrospection: table }
} = context;
if (!isPgRowSortEnum || !table || table.kind !== "class") {

@@ -19,0 +21,0 @@ return values;

@@ -13,3 +13,5 @@ "use strict";

} = build;
const { scope: { isPgRowSortEnum, pgIntrospection: table } } = context;
const {
scope: { isPgRowSortEnum, pgIntrospection: table }
} = context;
if (!isPgRowSortEnum || !table || table.kind !== "class") {

@@ -16,0 +18,0 @@ return values;

@@ -30,3 +30,6 @@ "use strict";

} = build;
const { scope: { isRootQuery }, fieldWithHooks } = context;
const {
scope: { isRootQuery },
fieldWithHooks
} = context;
if (!isRootQuery) {

@@ -33,0 +36,0 @@ return fields;

@@ -30,3 +30,6 @@ "use strict";

} = build;
const { scope: { isRootQuery }, fieldWithHooks } = context;
const {
scope: { isRootQuery },
fieldWithHooks
} = context;
if (!isRootQuery) {

@@ -76,3 +79,5 @@ return fields;

if (debugSql.enabled) debugSql(text);
const { rows: [row] } = await pgClient.query(text, values);
const {
rows: [row]
} = await pgClient.query(text, values);
return row;

@@ -79,0 +84,0 @@ }

@@ -26,3 +26,5 @@ "use strict";

} = build;
const { scope: { isPgRowType, pgIntrospection: table } } = context;
const {
scope: { isPgRowType, pgIntrospection: table }
} = context;
if (!isPgRowType || !table.namespace || omit(table, "read")) {

@@ -49,3 +51,5 @@ return object;

if (debugSql.enabled) debugSql(text);
const { rows: [row] } = await pgClient.query(text, values);
const {
rows: [row]
} = await pgClient.query(text, values);
return row;

@@ -71,3 +75,6 @@ });

} = build;
const { scope: { isRootQuery }, fieldWithHooks } = context;
const {
scope: { isRootQuery },
fieldWithHooks
} = context;
if (!isRootQuery || !nodeIdFieldName) {

@@ -118,3 +125,5 @@ return fields;

if (debugSql.enabled) debugSql(text);
const { rows: [row] } = await pgClient.query(text, values);
const {
rows: [row]
} = await pgClient.query(text, values);
return row;

@@ -121,0 +130,0 @@ } catch (e) {

{
"name": "graphile-build-pg",
"version": "4.0.0-rc.3",
"version": "4.0.0-rc.4",
"description": "Build a GraphQL schema by reflection over a PostgreSQL schema. Easy to customize since it's built with plugins on graphile-build",

@@ -39,7 +39,7 @@ "main": "node8plus/index.js",

"debug": ">=2 <3",
"graphile-build": "4.0.0-rc.3",
"graphile-build": "4.0.0-rc.4",
"graphql-iso-date": "^3.2.0",
"jsonwebtoken": "^8.1.1",
"lodash": ">=4 <5",
"lru-cache": "4.1.1",
"lru-cache": ">=4 <5",
"pg-sql2": "2.1.0",

@@ -46,0 +46,0 @@ "postgres-interval": "1.1.1"

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc