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

factory-girl-default

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

factory-girl-default - npm Package Compare versions

Comparing version 1.0.10 to 1.0.11

19

index.js

@@ -145,19 +145,10 @@ /* global window, define */

factory.adapterFor = function (name) {
console.log('=============== START: adapterFor ===============');
console.log('adapters: ', adapters);
var adapter;
if (adapters[name] !== undefined) {
console.log('1 - ', adapters[name]);
adapter = adapters[name];
} else if (Object.keys(adapters).length > 0) {
console.log('2 - ', adapters[Object.keys(adapters)[0]], adapters);
adapter = adapters[Object.keys(adapters)[0]];
} else {
console.log('3 - ', defaultAdapter);
adapter = defaultAdapter;
}
console.log('selected adapter: ', adapter);
console.log('=============== END: adapterFor ===============');
return adapter;

@@ -357,6 +348,2 @@ };

var model = factories[name].model;
console.log('===========');
console.log('factory name!');
console.log(factories[name]);
attrs = merge(copy(factories[name].attributes), attrs);

@@ -375,8 +362,5 @@ var names = keys(attrs);

var adapter;
console.log(model.build);
if (model.build === undefined) {
console.log('default adapter');
adapter = defaultAdapter;
} else {
console.log('custom adater');
adapter = factory.adapterFor(name);

@@ -545,7 +529,4 @@ }

Adapter.prototype.build = function (Model, props) {
console.log('this is the build!');
var doc = new Model();
console.log('here is the doc', doc);
this.set(props, doc, Model);
console.log('and here is how the doc looks', doc);
return doc;

@@ -552,0 +533,0 @@ };

2

package.json

@@ -6,3 +6,3 @@ {

"author": "Gonzalo Santome",
"version": "1.0.10",
"version": "1.0.11",
"keywords": [

@@ -9,0 +9,0 @@ "factory",

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