Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cmbf-hapi-restmodel

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cmbf-hapi-restmodel - npm Package Compare versions

Comparing version 0.6.12 to 0.6.13

6

lib/base-model.js

@@ -158,3 +158,3 @@ var Joi = require('joi'),

save(data, options) {
data = data || this;
data = data || this.toJSON();
log.debug("Save", data[this.constructor.idField] || this[this.constructor.idField]);

@@ -171,7 +171,7 @@ options = options || {upsert: false};

var fieldsToRemove = _.pickBy(this.toJSON(), function (val) {
var fieldsToRemove = _.pickBy(data, function (val) {
return _.isNull(val);
});
var fieldsToUpdate = _.omitBy(this.toJSON(), function (val, key) {
var fieldsToUpdate = _.omitBy(data, function (val, key) {
return key === _this.constructor.idField || _.isNull(val);

@@ -178,0 +178,0 @@ });

{
"name": "cmbf-hapi-restmodel",
"version": "0.6.12",
"version": "0.6.13",
"author": "Joel Grenon <joelgrenon@covistra.com>",

@@ -5,0 +5,0 @@ "description": "Hapi plugin building a REST Api from Joi schema, backed by covistra-mongo plugin",

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