New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@pothos/plugin-relay

Package Overview
Dependencies
Maintainers
1
Versions
81
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pothos/plugin-relay - npm Package Compare versions

Comparing version 3.5.1 to 3.5.2

6

CHANGELOG.md
# Change Log
## 3.5.2
### Patch Changes
- 31f9e8be: Fix isTypeOf check not handling \_\_typename correctly
## 3.5.1

@@ -4,0 +10,0 @@

13

esm/schema-builder.js

@@ -104,8 +104,9 @@ import SchemaBuilder, { createContextCache, getTypeBrand, verifyRef, } from '@pothos/core';

try {
if (proto === null || proto === void 0 ? void 0 : proto.constructor) {
const config = this.configStore.getTypeConfig(proto.constructor);
return config.name === nodeName;
}
if (typeof maybeNode === "object") {
// eslint-disable-next-line no-underscore-dangle
const typename = maybeNode.__typename;
if (typename === nodeName) {
return true;
}
// eslint-disable-next-line no-underscore-dangle
const nodeRef = maybeNode.__type;

@@ -118,2 +119,6 @@ if (!nodeRef) {

}
if (proto === null || proto === void 0 ? void 0 : proto.constructor) {
const config = this.configStore.getTypeConfig(proto.constructor);
return config.name === nodeName;
}
}

@@ -120,0 +125,0 @@ catch {

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

try {
if (proto === null || proto === void 0 ? void 0 : proto.constructor) {
const config = this.configStore.getTypeConfig(proto.constructor);
return config.name === nodeName;
}
if (typeof maybeNode === 'object') {
// eslint-disable-next-line no-underscore-dangle
const typename = maybeNode.__typename;
if (typename === nodeName) {
return true;
}
// eslint-disable-next-line no-underscore-dangle
const nodeRef = maybeNode.__type;

@@ -140,2 +141,6 @@ if (!nodeRef) {

}
if (proto === null || proto === void 0 ? void 0 : proto.constructor) {
const config = this.configStore.getTypeConfig(proto.constructor);
return config.name === nodeName;
}
}

@@ -142,0 +147,0 @@ catch {

{
"name": "@pothos/plugin-relay",
"version": "3.5.1",
"version": "3.5.2",
"description": "A Pothos plugin for adding relay style connections, nodes, and cursor based pagination to your GraphQL schema",

@@ -38,3 +38,3 @@ "main": "./lib/index.js",

"devDependencies": {
"@pothos/core": "3.3.1",
"@pothos/core": "3.3.2",
"@pothos/test-utils": "1.0.2",

@@ -41,0 +41,0 @@ "graphql": "16.3.0",

@@ -181,9 +181,10 @@ /* eslint-disable @typescript-eslint/no-unsafe-return */

try {
if (proto?.constructor) {
const config = this.configStore.getTypeConfig(proto.constructor as OutputRef);
if (typeof maybeNode === 'object') {
// eslint-disable-next-line no-underscore-dangle
const typename = (maybeNode as { __typename: string }).__typename;
return config.name === nodeName;
}
if (typename === nodeName) {
return true;
}
if (typeof maybeNode === 'object') {
// eslint-disable-next-line no-underscore-dangle

@@ -200,2 +201,8 @@ const nodeRef = (maybeNode as { __type: OutputRef }).__type;

}
if (proto?.constructor) {
const config = this.configStore.getTypeConfig(proto.constructor as OutputRef);
return config.name === nodeName;
}
} catch {

@@ -202,0 +209,0 @@ // ignore

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