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

minimonk

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

minimonk - npm Package Compare versions

Comparing version 1.2.0 to 1.2.1

2

lib/minimonk.d.ts

@@ -33,3 +33,3 @@ import { ICollection, IMonkManager } from "monk";

export declare class Manager {
manager: IMonkManager;
manager: Promise<IMonkManager> & IMonkManager;
constructor(uri: string);

@@ -36,0 +36,0 @@ get<TSchema extends Document>(name: string): Collection<TSchema>;

@@ -49,13 +49,16 @@ "use strict";

};
var __spreadArrays = (this && this.__spreadArrays) || function () {
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
for (var r = Array(s), k = 0, i = 0; i < il; i++)
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
r[k] = a[j];
return r;
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
if (ar || !(i in from)) {
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
ar[i] = from[i];
}
}
return to.concat(ar || Array.prototype.slice.call(from));
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.Collection = exports.Manager = exports.idify = exports.ObjectID = void 0;
var monk_1 = require("monk");
var bson_1 = require("bson");
exports.ObjectID = bson_1.ObjectID;
Object.defineProperty(exports, "ObjectID", { enumerable: true, get: function () { return bson_1.ObjectID; } });
function idify(str) {

@@ -69,3 +72,3 @@ // Safeguard for the old behaviour, to remove after backend TS conversion is over

if (!bson_1.ObjectID.isValid(str))
throw new Error("Invalid hex value <" + str + "> passed to idify");
throw new Error("Invalid hex value <".concat(str, "> passed to idify"));
return bson_1.ObjectID.createFromHexString(str);

@@ -76,3 +79,3 @@ }

function Manager(uri) {
this.manager = monk_1.default(uri);
this.manager = (0, monk_1.default)(uri);
}

@@ -135,4 +138,4 @@ Manager.prototype.get = function (name) {

return __awaiter(this, void 0, void 0, function () {
var rootFilter, _a;
var _b;
var rootFilter;
var _a, _b;
return __generator(this, function (_c) {

@@ -142,3 +145,3 @@ switch (_c.label) {

rootFilter = {
$and: __spreadArrays([filter], (search ? [{ $text: { $search: search } }] : []))
$and: __spreadArray([filter], (search ? [{ $text: { $search: search } }] : []), true)
};

@@ -145,0 +148,0 @@ _a = {};

{
"name": "minimonk",
"version": "1.2.0",
"version": "1.2.1",
"description": "A tiny wrapper around monk",

@@ -17,4 +17,4 @@ "main": "lib/minimonk.js",

"monk": "6.0.6",
"typescript": "^3.7.5"
"typescript": "^4.6.4"
}
}

@@ -64,3 +64,3 @@ import monk, { ICollection, IMonkManager } from "monk";

export class Manager {
manager: IMonkManager;
manager: Promise<IMonkManager> & IMonkManager;

@@ -67,0 +67,0 @@ constructor(uri: string) {

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