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

es-alchemy

Package Overview
Dependencies
Maintainers
1
Versions
318
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

es-alchemy - npm Package Compare versions

Comparing version 3.3.2 to 3.3.3

6

lib/util/query.js

@@ -7,3 +7,3 @@ const assert = require('assert');

const objectPaths = require('obj-paths');
const objectFields = require('object-fields');

@@ -78,3 +78,3 @@ const actionMap = require('../resources/action-map');

const result = {
_source: typeof toReturn === 'string' ? objectPaths.split(toReturn) : toReturn,
_source: typeof toReturn === 'string' ? objectFields.split(toReturn) : toReturn,
size,

@@ -108,2 +108,2 @@ from

};
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy91dGlsL3F1ZXJ5LmpzIl0sIm5hbWVzIjpbImFzc2VydCIsInJlcXVpcmUiLCJnZXQiLCJpc0VxdWFsIiwib2JqZWN0UGF0aHMiLCJhY3Rpb25NYXAiLCJmcm9tQ3Vyc29yIiwiYnVpbGRRdWVyeVJlYyIsImZpbHRlckJ5IiwiYWxsb3dlZEZpZWxkcyIsIkFycmF5IiwiaXNBcnJheSIsImluY2x1ZGVzIiwic3Vic3RyaW5nIiwibGFzdEluZGV4T2YiLCJmaWx0ZXIiLCJzbGljZSIsImZpbHRlcktleXMiLCJPYmplY3QiLCJrZXlzIiwiSlNPTiIsInN0cmluZ2lmeSIsInNvcnQiLCJjbGF1c2UiLCJlIiwiZmlsdGVycyIsInRhcmdldCIsImdyb3VwcyIsImZvckVhY2giLCJwcmVmaXgiLCJsb2dpYyIsInNwbGl0IiwidW5kZWZpbmVkIiwicHVzaCIsInJlc3VsdHMiLCJlbnRyaWVzIiwibG9naWNzIiwibmVzdCIsImJvb2wiLCJtb2R1bGUiLCJleHBvcnRzIiwiYnVpbGQiLCJ0b1JldHVybiIsIm9yZGVyQnkiLC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0ZXJCeS5sZW5ndGggIT09IDApIHtcbiAgICByZXN1bHQucXVlcnkgPSBidWlsZFF1ZXJ5UmVjKGZpbHRlckJ5LCBhbGxvd2VkRmllbGRzKVsxXTtcbiAgfVxuICBpZiAoc2NvcmVCeS5sZW5ndGggIT09IDApIHtcbiAgICByZXN1bHQucXVlcnkgPSB7XG4gICAgICBmdW5jdGlvbl9zY29yZToge1xuICAgICAgICBxdWVyeTogZ2V0KHJlc3VsdCwgJ3F1ZXJ5JywgeyBtYXRjaF9hbGw6IHt9IH0pLFxuICAgICAgICBmdW5jdGlvbnM6IHNjb3JlQnkubWFwKGUgPT4gYWN0aW9uTWFwLnNjb3JlW2VbMF1dKC4uLmUuc2xpY2UoMSkpKSxcbiAgICAgICAgc2NvcmVfbW9kZTogJ3N1bScsXG4gICAgICAgIGJvb3N0X21vZGU6ICdyZXBsYWNlJ1xuICAgICAgfVxuICAgIH07XG4gIH1cbiAgcmVzdWx0LnNvcnQgPSBbXG4gICAgLi4ub3JkZXJCeSxcbiAgICAuLi4oc2NvcmVCeS5sZW5ndGggIT09IDAgPyBbWydfc2NvcmUnLCAnZGVzYycsIG51bGxdXSA6IFtdKSxcbiAgICAuLi4oZ2V0KG9yZGVyQnkuc2xpY2UoLTEpLCAnWzBdWzBdJykgPT09ICdpZCcgJiYgWydhc2MnLCAnZGVzYyddLmluY2x1ZGVzKGdldChvcmRlckJ5LnNsaWNlKC0xKSwgJ1swXVsxXScpKVxuICAgICAgPyBbXVxuICAgICAgOiBbWydpZCcsICdhc2MnXV0pXG4gIF1cbiAgICAubWFwKGUgPT4gYWN0aW9uTWFwLm9yZGVyW2VbMV1dKGVbMF0sIC4uLmUuc2xpY2UoMikpKTtcbiAgcmV0dXJuIHJlc3VsdDtcbn07XG4iXX0=

@@ -7,7 +7,5 @@ const assert = require('assert');

const objectRewrite = require('object-rewrite');
const objectScan = require('object-scan');
const objectPaths = require('obj-paths');
const objectFields = require('object-fields');

@@ -22,3 +20,3 @@ const resultRemap = require('../../../resources/result-remap');

filterNew._source.push(...objectPaths.getParents(filterNew._source).map(p => `${p}.id`)); // eslint-disable-next-line no-underscore-dangle
filterNew._source.push(...objectFields.getParents(filterNew._source).map(p => `${p}.id`)); // eslint-disable-next-line no-underscore-dangle

@@ -61,3 +59,3 @@

// eslint-disable-next-line no-underscore-dangle
const arrays = objectPaths.getParents(filter._source).filter(e => rels[e].endsWith('[]')).map(e => e.split('.')).reduce((p, c) => {
const arrays = objectFields.getParents(filter._source).filter(e => rels[e].endsWith('[]')).map(e => e.split('.')).reduce((p, c) => {
const key = c.slice(0, -1).join('.');

@@ -85,10 +83,4 @@ const value = c.slice(-1).join('.');

})(input);
})(); // PART 3: workaround for https://github.com/elastic/elasticsearch/issues/23796
// filter injected ids out for final result
})();
const rewriterRetain = objectRewrite({
// eslint-disable-next-line no-underscore-dangle
retain: filter._source.map(e => e === '' ? '**' : `${e}.**`)
});
esResult.body.hits.hits.forEach(r => {

@@ -98,8 +90,10 @@ // eslint-disable-next-line no-underscore-dangle

injectArrays(r._source); // eslint-disable-next-line no-underscore-dangle
injectArrays(r._source); // PART 3: workaround for https://github.com/elastic/elasticsearch/issues/23796
// filter injected ids out for final result
// eslint-disable-next-line no-underscore-dangle
rewriterRetain(r._source);
objectFields.retain(r._source, filter._source);
});
return esResult.body;
});
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy91dGlsL3Jlc3QvZGF0YS9xdWVyeS5qcyJdLCJuYW1lcyI6WyJhc3NlcnQiLCJyZXF1aXJlIiwiZ2V0IiwiY2xvbmVEZWVwIiwib2JqZWN0UmV3cml0ZSIsIm9iamVjdFNjYW4iLCJvYmplY3RQYXRocyIsInJlc3VsdFJlbWFwIiwibW9kdWxlIiwiZXhwb3J0cyIsImNhbGwiLCJpZHgiLCJyZWxzIiwibWFwcGluZyIsImZpbHRlciIsImJvZHkiLCJmaWx0ZXJOZX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wLCAtMSkuam9pbignLicpO1xuICAgICAgICAgIGNvbnN0IHZhbHVlID0gYy5zbGljZSgtMSkuam9pbignLicpO1xuICAgICAgICAgIHJldHVybiBPYmplY3QuYXNzaWduKHAsIHsgW2tleV06IChwW2tleV0gfHwgW10pLmNvbmNhdCh2YWx1ZSkgfSk7XG4gICAgICAgIH0sIHt9KTtcbiAgICAgIHJldHVybiBpbnB1dCA9PiBvYmplY3RTY2FuKE9iamVjdC5rZXlzKGFycmF5cyksIHtcbiAgICAgICAgam9pbmVkOiBmYWxzZSxcbiAgICAgICAgdXNlQXJyYXlTZWxlY3RvcjogZmFsc2UsXG4gICAgICAgIGZpbHRlckZuOiAoa2V5LCB2YWx1ZSwgeyBtYXRjaGVkQnkgfSkgPT4ge1xuICAgICAgICAgIG1hdGNoZWRCeS5mb3JFYWNoKChtKSA9PiB7XG4gICAgICAgICAgICBhcnJheXNbbV0uZm9yRWFjaCgoZSkgPT4ge1xuICAgICAgICAgICAgICBpZiAodmFsdWVbZV0gPT09IHVuZGVmaW5lZCkge1xuICAgICAgICAgICAgICAgIC8vIGVzbGludC1kaXNhYmxlLW5leHQtbGluZSBuby1wYXJhbS1yZWFzc2lnblxuICAgICAgICAgICAgICAgIHZhbHVlW2VdID0gW107XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgICB9KShpbnB1dCk7XG4gICAgfSkoKTtcbiAgICBlc1Jlc3VsdC5ib2R5LmhpdHMuaGl0cy5mb3JFYWNoKChyKSA9PiB7XG4gICAgICAvLyBlc2xpbnQtZGlzYWJsZS1uZXh0LWxpbmUgbm8tdW5kZXJzY29yZS1kYW5nbGVcbiAgICAgIHJld3JpdGVyUmVtYXAoci5fc291cmNlKTtcbiAgICAgIC8vIGVzbGludC1kaXNhYmxlLW5leHQtbGluZSBuby11bmRlcnNjb3JlLWRhbmdsZVxuICAgICAgaW5qZWN0QXJyYXlzKHIuX3NvdXJjZSk7XG4gICAgICAvLyBQQVJUIDM6IHdvcmthcm91bmQgZm9yIGh0dHBzOi8vZ2l0aHViLmNvbS9lbGFzdGljL2VsYXN0aWNzZWFyY2gvaXNzdWVzLzIzNzk2XG4gICAgICAvLyBmaWx0ZXIgaW5qZWN0ZWQgaWRzIG91dCBmb3IgZmluYWwgcmVzdWx0XG4gICAgICAvLyBlc2xpbnQtZGlzYWJsZS1uZXh0LWxpbmUgbm8tdW5kZXJzY29yZS1kYW5nbGVcbiAgICAgIG9iamVjdEZpZWxkcy5yZXRhaW4oci5fc291cmNlLCBmaWx0ZXIuX3NvdXJjZSk7XG4gICAgfSk7XG4gICAgcmV0dXJuIGVzUmVzdWx0LmJvZHk7XG4gIH0pO1xuIl19
{
"name": "es-alchemy",
"version": "3.3.2",
"version": "3.3.3",
"description": "Simplification of Elasticsearch interactions",

@@ -100,5 +100,4 @@ "main": "lib/index.js",

"lodash.isequal": "4.5.0",
"obj-paths": "1.3.1",
"object-fields": "1.3.5",
"object-hash": "1.3.1",
"object-rewrite": "2.1.33",
"object-scan": "10.0.1"

@@ -105,0 +104,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