Socket
Socket
Sign inDemoInstall

nothinkdb

Package Overview
Dependencies
Maintainers
1
Versions
55
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nothinkdb - npm Package Compare versions

Comparing version 0.5.7 to 0.5.8

31

lib/Table.js

@@ -340,10 +340,2 @@ /* eslint no-shadow: 0, no-param-reassign: 0 */

}, {
key: '_withJoinOne',
value: function _withJoinOne(query, relationName, options) {
var relation = this.getRelation(relationName);
return query.merge(function (row) {
return _defineProperty({}, relationName, relation.coerceType(relation.query(row, options)));
});
}
}, {
key: 'withJoin',

@@ -354,11 +346,9 @@ value: function withJoin(query, relations) {

return _lodash2['default'].reduce(relations, function (query, relations, key) {
var options = _lodash2['default'].isObject(relations) ? relations : {};
if (_lodash2['default'].startsWith(key, '_')) return query;
query = _this5._withJoinOne(query, key, options);
if (_lodash2['default'].isObject(relations)) {
(function () {
var relations = _lodash2['default'].omitBy(relations, function (relations, key) {
return _lodash2['default'].startsWith(key, '_');
});
var relation = _this5.getRelation(key);
query = query.merge(function (row) {
var relatedQuery = relation.coerceType(relation.query(row, relations));
if (_lodash2['default'].isObject(relations)) {
var _getRelation = _this5.getRelation(key);

@@ -368,7 +358,8 @@

query = query.merge(function (row) {
return _defineProperty({}, key, targetTable.withJoin(row(key), relations));
});
})();
}
relatedQuery = targetTable.withJoin(relatedQuery, relations);
}
return _defineProperty({}, key, relatedQuery);
});
return query;

@@ -375,0 +366,0 @@ }, query);

{
"name": "nothinkdb",
"version": "0.5.7",
"version": "0.5.8",
"description": "Functional toolkit for rethinkdb",

@@ -40,3 +40,3 @@ "main": "lib/nothinkdb.js",

"mocha": "^2.4.5",
"rethinkdb": "^2.2.2",
"rethinkdb": "2.2.3",
"rimraf": "^2.5.1"

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