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

cool-data-manager

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cool-data-manager - npm Package Compare versions

Comparing version 1.0.16 to 1.0.17

schema.json

3

package.json
{
"name": "cool-data-manager",
"version": "1.0.16",
"version": "1.0.17",
"description": "",

@@ -12,2 +12,3 @@ "main": "index.js",

"fbkt-clog": "^1.0.1",
"get-graphql-schema": "^1.0.1",
"lokka": "^1.7.0"

@@ -14,0 +15,0 @@ },

@@ -45,5 +45,7 @@ const Promise = require('bluebird');

return buildRelationOrCollectionOutputList(fieldName, field.type, options, acc);
} else {
} else if (field.queryExclude !== true) {
return Promise.resolve(acc.concat(` ${fieldName},
`));
} else {
return Promise.resolve(acc);
}

@@ -50,0 +52,0 @@ },

@@ -0,1 +1,3 @@

const CoolRelation = require('../coolRelation');
const ClientWrapper = require('./clientWrapper');

@@ -10,5 +12,34 @@ const CreateOne = require('./createOne');

function processEntityInfo(entityInfo){
const fields = Object.keys(entityInfo.fields).reduce(
(acc, fieldName) => {
if (entityInfo.fields[fieldName].type instanceof CoolRelation) {
return Object.assign(acc, {
[fieldName]: entityInfo.fields[fieldName],
[`${fieldName}Id`]: {
type: 'string',
queryExclude: true
}
})
} else {
return Object.assign(acc, {
[fieldName]: entityInfo.fields[fieldName]
})
}
},
{}
);
return {
entityName: entityInfo.entityName,
entityNamePlural: entityInfo.entityNamePlural,
fields: fields
};
}
class CoolDataManager{
constructor(entityInfo, client, options){
this.entityInfo = entityInfo;
this.entityInfo = processEntityInfo(entityInfo);
clog('THIS ENTITYINFO', this.entityInfo);
this.client = new ClientWrapper(client, options);

@@ -15,0 +46,0 @@ }

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