Socket
Socket
Sign inDemoInstall

sails-disk

Package Overview
Dependencies
128
Maintainers
4
Versions
47
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.0.0 to 2.1.0

8

index.js

@@ -429,3 +429,3 @@ /**

// Normalize the stage-3 query criteria into NeDB (really, MongoDB) criteria.
var where = normalizeWhere(query.criteria.where);
var where = normalizeWhere(query.criteria.where, query.meta);

@@ -512,3 +512,3 @@ // Transform the stage-3 query sort array into an NeDB sort dictionary.

// Normalize the stage-3 query criteria into NeDB (really, MongoDB) criteria.
var where = normalizeWhere(query.criteria.where);
var where = normalizeWhere(query.criteria.where, query.meta);

@@ -617,3 +617,3 @@ // If the user is attempting to change the primary key, do a drop/add instead.

// Normalize the stage-3 query criteria into NeDB (really, MongoDB) criteria.
var where = normalizeWhere(query.criteria.where);
var where = normalizeWhere(query.criteria.where, query.meta);

@@ -709,3 +709,3 @@ // Remove the documents from the db.

// Normalize the stage-3 query criteria into NeDB (really, MongoDB) criteria.
var where = normalizeWhere(query.criteria.where);
var where = normalizeWhere(query.criteria.where, query.meta);

@@ -712,0 +712,0 @@ // Count the documents into the db.

@@ -7,3 +7,3 @@ /**

module.exports = function normalizeWhereClause (_whereClause) {
module.exports = function normalizeWhereClause (_whereClause, meta) {

@@ -83,3 +83,9 @@ // Clone the where clause so that we don't modify the original query object.

case 'like':
val['$regex'] = new RegExp('^'+_.escapeRegExp(modified).replace(/^%/, '.*').replace(/([^\\])%/g, '$1.*').replace(/\\%/g, '%')+'$');
let regexpAsString = '^'+_.escapeRegExp(modified).replace(/^%/, '.*').replace(/([^\\])%/g, '$1.*').replace(/\\%/g, '%')+'$';
if (meta && meta.makeLikeModifierCaseInsensitive) {
val['$regex'] = new RegExp(regexpAsString, 'i');
} else {
val['$regex'] = new RegExp(regexpAsString);
}
break;

@@ -86,0 +92,0 @@

{
"name": "sails-disk",
"version": "2.0.0",
"version": "2.1.0",
"description": "Persistent local-disk (and/or memory) adapter for Sails.js / Waterline.",

@@ -5,0 +5,0 @@ "main": "index.js",

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc