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

@typegoose/typegoose

Package Overview
Dependencies
Maintainers
1
Versions
223
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@typegoose/typegoose - npm Package Compare versions

Comparing version 6.1.0-10 to 6.1.0-11

60

lib/index.d.ts

@@ -1,58 +0,2 @@

export interface IndexOptions<T> {
/**
* Mongoose-specific syntactic sugar, uses ms to convert
* expires option into seconds for the expireAfterSeconds in the above link.
*/
expires?: string;
/**
* Creates an unique index.
*/
unique?: boolean;
/**
* Creates a sparse index.
*/
sparse?: boolean;
/**
* Creates the index in the background, yielding whenever possible.
*/
background?: boolean;
/**
* A unique index cannot be created on a key that has pre-existing duplicate values.
* If you would like to create the index anyway, keeping the first document the database indexes and
* deleting all subsequent documents that have duplicate value
*/
dropDups?: boolean;
/**
* For geo spatial indexes set the lower bound for the co-ordinates.
*/
min?: number;
/**
* For geo spatial indexes set the high bound for the co-ordinates.
*/
max?: number;
/**
* Specify the format version of the indexes.
*/
v?: number;
/**
* Allows you to expire data on indexes applied to a data (MongoDB 2.2 or higher)
*/
expireAfterSeconds?: number;
/**
* Override the auto generated index name (useful if the resulting name is larger than 128 bytes)
*/
name?: string;
/**
* Creates a partial index based on the given filter object (MongoDB 3.2 or higher)
*/
partialFilterExpression?: any;
collation?: object;
default_language?: string;
lowercase?: boolean;
uppercase?: boolean;
trim?: boolean;
weights?: {
[P in keyof Partial<T>]: number;
};
}
import { IndexOptions } from './types';
/**

@@ -68,2 +12,2 @@ * Defines an index (most likely compound) for this schema.

*/
export declare function index<T>(fields: T, options?: IndexOptions<T>): (target: any) => void;
export declare function index<T = {}>(fields: T, options?: IndexOptions<T>): (target: any) => void;

2

lib/index.js

@@ -22,2 +22,2 @@ "use strict";

exports.index = index;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2V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FBQztRQUNsQyxPQUFPLENBQUMsY0FBYyxDQUFDLHlCQUFhLENBQUMsS0FBSyxFQUFFLE9BQU8sRUFBRSxNQUFNLENBQUMsQ0FBQztJQUMvRCxDQUFDLENBQUM7QUFDSixDQUFDO0FBTkQsc0JBTUMifQ==

@@ -50,3 +50,3 @@ "use strict";

const hook = data_1.hooks.get(name);
if (hook) {
if (!util_1.isNullOrUndefined(hook)) {
hook.pre.forEach((obj) => {

@@ -65,3 +65,3 @@ sch.pre(obj.method, obj.func);

const virtualPopulates = data_1.virtuals.get(name);
if (virtualPopulates) {
if (!util_1.isNullOrUndefined(virtualPopulates)) {
for (const [key, options] of virtualPopulates) {

@@ -74,5 +74,7 @@ logSettings_1.logger.debug('Applying Virtual Populates:', key, options);

const indices = Reflect.getMetadata(constants_1.DecoratorKeys.Index, cl) || [];
for (const index of indices) {
logSettings_1.logger.debug('Applying Index:', index);
sch.index(index.fields, index.options);
if (!util_1.isNullOrUndefined(indices) && Array.isArray(indices)) {
for (const index of indices) {
logSettings_1.logger.debug('Applying Index:', index);
sch.index(index.fields, index.options);
}
}

@@ -82,2 +84,2 @@ return sch;

exports._buildSchema = _buildSchema;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2NoZW1hLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL2ludGVybmFsL3NjaGVtYS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHFDQUFxQztBQUVyQywrQkFBeUM7QUFDekMsZ0RBQXdDO0FBQ3hDLGtDQUE2QztBQUU3QywyQ0FBNEM7QUFDNUMsaUNBQTJEO0FBQzNELHFDQUF3QztBQUN4QyxtQ0FBc0Q7QUFFdEQ7Ozs7Ozs7O0dBUUc7QUFDSCxTQUFnQixZQUFZLENBQzFCLEVBQUssRUFDTCxHQUFxQixFQUNyQixHQUE0QjtJQUU1QixJQUFJLE9BQU8sRUFBRSxLQ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UFBRSxPQUFPLENBQUMsQ0FBQztZQUMxRCxHQUFHLENBQUMsT0FBTyxDQUFDLEdBQUcsRUFBRSxPQUFPLENBQUMsQ0FBQztTQUMzQjtLQUNGO0lBRUQsK0JBQStCO0lBQy9CLE1BQU0sT0FBTyxHQUF1QixPQUFPLENBQUMsV0FBVyxDQUFDLHlCQUFhLENBQUMsS0FBSyxFQUFFLEVBQUUsQ0FBQyxJQUFJLEVBQUUsQ0FBQztJQUN2RixJQUFJLENBQUMsd0JBQWlCLENBQUMsT0FBTyxDQUFDLElBQUksS0FBSyxDQUFDLE9BQU8sQ0FBQyxPQUFPLENBQUMsRUFBRTtRQUN6RCxLQUFLLE1BQU0sS0FBSyxJQUFJLE9BQU8sRUFBRTtZQUMzQixvQkFBTSxDQUFDLEtBQUssQ0FBQyxpQkFBaUIsRUFBRSxLQUFLLENBQUMsQ0FBQztZQUN2QyxHQUFHLENBQUMsS0FBSyxDQUFDLEtBQUssQ0FBQyxNQUFNLEVBQUUsS0FBSyxDQUFDLE9BQU8sQ0FBQyxDQUFDO1NBQ3hDO0tBQ0Y7SUFFRCxPQUFPLEdBQUcsQ0FBQztBQUNiLENBQUM7QUE3RUQsb0NBNkVDIn0=

@@ -118,3 +118,12 @@ import * as mongoose from 'mongoose';

* @param Type The Type of the array
* @param target The Target class
* @param pkey Key of the Property
*/
export declare function mapArrayOptions(rawOptions: any, Type: AnyParamConstructor<any>): mongoose.SchemaTypeOpts<any>;
export declare function mapArrayOptions(rawOptions: any, Type: AnyParamConstructor<any>, target: any, pkey: string): mongoose.SchemaTypeOpts<any>;
/**
* Warn, Error or Allow if an mixed type is set
* -> this function exists for de-duplication
* @param target Target Class
* @param key Property key
*/
export declare function warnMixed(target: any, key: string | symbol): void | never;

@@ -7,2 +7,3 @@ "use strict";

const logSettings_1 = require("../logSettings");
const types_1 = require("../types");
const constants_1 = require("./constants");

@@ -34,13 +35,14 @@ const data_1 = require("./data");

function isObject(Type) {
let prototype = Type.prototype;
let name = Type.name;
while (name) {
if (name === 'Object') {
return true;
if (typeof Type.name === 'string') {
let prototype = Type.prototype;
let name = Type.name;
while (name) {
if (name === 'Object') {
return true;
}
prototype = Object.getPrototypeOf(prototype);
name = prototype ? prototype.constructor.name : null;
}
prototype = Object.getPrototypeOf(prototype);
name = prototype ? prototype.constructor.name : null;
}
return false; // can this even return false?
// return !isNullOrUndefined(Type) && (typeof Type === 'object' || Type.name === 'Object') && !Array.isArray(Type);
return false;
}

@@ -146,11 +148,2 @@ exports.isObject = isObject;

/**
* Check if the given value has options of "IModelOptions"
* @param value The Value to evaulate
* @internal
*/
function isModelOptions(value) {
return value && (typeof value.schemaOptions === 'object' ||
typeof value.options === 'object');
}
/**
* Merge value & existing Metadata & Save it to the class

@@ -268,4 +261,6 @@ * Difference with "mergeMetadata" is that this one DOES save it to the class

* @param Type The Type of the array
* @param target The Target class
* @param pkey Key of the Property
*/
function mapArrayOptions(rawOptions, Type) {
function mapArrayOptions(rawOptions, Type, target, pkey) {
if (getName(Type) in mongoose.Schema.Types) {

@@ -276,3 +271,3 @@ logSettings_1.logger.info('Converting "%s" to mongoose Type', getName(Type));

if (Type === mongoose.Schema.Types.Mixed) {
logSettings_1.logger.warn('Converted Type to Mixed!');
warnMixed(target, pkey);
}

@@ -318,2 +313,26 @@ }

exports.mapArrayOptions = mapArrayOptions;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvaW50ZXJuYWwvdXRpbHMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxxQ0FBcUM7QUFFckMsbUNBQWtEO0FBQ2xELCtCQUF5QztBQUN6QyxnREFBd0M7QUFReEMsMkNBQTRDO0FBQzVDLGlDQUErQztBQUMvQyxxQ0FBd0M7QUFFeEM7Ozs7R0FJRztBQUNILFNBQWdCLFdBQVcsQ0FBQyxJQUFTO0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RjtJQUVELG9CQUFNLENBQUMsS0FBSyxDQUFDLG9DQUFvQyxFQUFFLE9BQU8sQ0FBQyxJQUFJLENBQUMsRUFBRSxZQUFZLENBQUMsQ0FBQztJQUVoRixPQUFPLFlBQVksQ0FBQztBQUN0QixDQUFDO0FBbERELDBDQWtEQyJ9
/**
* Warn, Error or Allow if an mixed type is set
* -> this function exists for de-duplication
* @param target Target Class
* @param key Property key
*/
function warnMixed(target, key) {
const name = getName(target);
const modelOptions = Reflect.getMetadata(constants_1.DecoratorKeys.ModelOptions, target) || {};
if (modelOptions.options) {
switch (modelOptions.options.allowMixed) {
default:
case types_1.Severity.WARN:
logSettings_1.logger.warn('Implicitly setting "Mixed" is not allowed! (%s, %s)', name, key);
return;
case types_1.Severity.ALLOW:
return;
case types_1.Severity.ERROR:
throw new TypeError(util_1.format('Implicitly setting "Mixed" is not allowed! (%s, %s)', name, key));
}
}
return; // always return, if "allowMixed" is not set
}
exports.warnMixed = warnMixed;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvaW50ZXJuYWwvdXRpbHMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxxQ0FBcUM7QUFFckMsbUNBQWtEO0FBQ2xELCtCQUFpRDtBQUNqRCxnREFBd0M7QUFDeEMsb0NBT2tCO0FBQ2xCLDJDQUE0QztBQUM1QyxpQ0FBK0M7QUFDL0MscUNBQXdDO0FBRXhDOzs7O0dBSUc7QUFDSCxTQUFnQixXQUFXLENBQUMsSUFBUztJQUNuQyxJQUFJLElBQUksSUFBSSxPQUFPLElBQUksQ0FBQyxJQUFJLEtBQUssUUFBUSxFQUFFO1FBQ3pDLGtGQUFrRjtRQUNsRixzREFBc0Q7UUFDdEQsT0FBTyxNQUFNLENBQUMsbUJBQW1CLENBQUMsUUFBUSxDQUFDLE1BQU0sQ0F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BQUMsV0FBVyxDQUFDLHlCQUFhLENBQUMsWUFBWSxFQUFFLE1BQU0sQ0FBQyxJQUFJLEVBQUUsQ0FBQztJQUVuRixJQUFJLFlBQVksQ0FBQyxPQUFPLEVBQUU7UUFDeEIsUUFBUSxZQUFZLENBQUMsT0FBTyxDQUFDLFVBQVUsRUFBRTtZQUN2QyxRQUFRO1lBQ1IsS0FBSyxnQkFBUSxDQUFDLElBQUk7Z0JBQ2hCLG9CQUFNLENBQUMsSUFBSSxDQUFDLHFEQUFxRCxFQUFFLElBQUksRUFBRSxHQUFHLENBQUMsQ0FBQztnQkFFOUUsT0FBTztZQUNULEtBQUssZ0JBQVEsQ0FBQyxLQUFLO2dCQUNqQixPQUFPO1lBQ1QsS0FBSyxnQkFBUSxDQUFDLEtBQUs7Z0JBQ2pCLE1BQU0sSUFBSSxTQUFTLENBQUMsYUFBTSxDQUFDLHFEQUFxRCxFQUFFLElBQUksRUFBRSxHQUFHLENBQUMsQ0FBQyxDQUFDO1NBQ2pHO0tBQ0Y7SUFFRCxPQUFPLENBQUMsNENBQTRDO0FBQ3RELENBQUM7QUFuQkQsOEJBbUJDIn0=

@@ -75,3 +75,3 @@ "use strict";

const newType = rawOptions && rawOptions.type ? rawOptions.type : Type;
if (rawOptions && rawOptions.type) {
if (!util_1.isNullOrUndefined(rawOptions && rawOptions.type)) {
delete rawOptions.type;

@@ -89,3 +89,3 @@ }

const refType = rawOptions.refType || rawOptions.type || mongoose.Schema.Types.ObjectId;
if (ref) {
if (!util_1.isNullOrUndefined(ref)) {
delete rawOptions.ref;

@@ -124,3 +124,3 @@ const refName = typeof ref === 'string' ? ref : utils.getName(ref);

const enumOption = rawOptions.enum;
if (enumOption) {
if (!util_1.isNullOrUndefined(enumOption)) {
if (!Array.isArray(enumOption)) {

@@ -134,17 +134,19 @@ rawOptions.enum = Object.keys(enumOption).map((propKey) => enumOption[propKey]);

}
// check if Type is actually a real working Type
if (util_1.isNullOrUndefined(Type) || typeof Type !== 'function') {
throw new errors_1.InvalidTypeError(target.constructor.name, key, Type);
{
// check if Type is actually a real working Type
if (util_1.isNullOrUndefined(Type) || typeof Type !== 'function') {
throw new errors_1.InvalidTypeError(target.constructor.name, key, Type);
}
// check for validation inconsistencies
if (utils.isWithStringValidate(rawOptions) && !utils.isString(Type)) {
throw new errors_1.NotStringTypeError(key);
}
// check for transform inconsistencies
if (utils.isWithStringTransform(rawOptions) && !utils.isString(Type)) {
throw new errors_1.NotStringTypeError(key);
}
if (utils.isWithNumberValidate(rawOptions) && !utils.isNumber(Type)) {
throw new errors_1.NotNumberTypeError(key);
}
}
// check for validation inconsistencies
if (utils.isWithStringValidate(rawOptions) && !utils.isString(Type)) {
throw new errors_1.NotStringTypeError(key);
}
// check for transform inconsistencies
if (utils.isWithStringTransform(rawOptions) && !utils.isString(Type)) {
throw new errors_1.NotStringTypeError(key);
}
if (utils.isWithNumberValidate(rawOptions) && !utils.isNumber(Type)) {
throw new errors_1.NotNumberTypeError(key);
}
const subSchema = data_1.schemas.get(utils.getName(Type));

@@ -158,3 +160,3 @@ if (!subSchema && !utils.isPrimitive(Type) && !utils.isObject(Type)) {

case types_1.WhatIsIt.ARRAY:
data_1.schemas.get(name)[key] = Object.assign(Object.assign({}, data_1.schemas.get(name)[key][0]), utils.mapArrayOptions(rawOptions, Type));
data_1.schemas.get(name)[key] = Object.assign(Object.assign({}, data_1.schemas.get(name)[key][0]), utils.mapArrayOptions(rawOptions, Type, target, key));
return;

@@ -178,15 +180,5 @@ case types_1.WhatIsIt.MAP:

if (utils.isObject(Type) && !subSchema) {
const modelOptions = Reflect.getMetadata(constants_1.DecoratorKeys.ModelOptions, target) || {};
if (modelOptions.options) {
switch (modelOptions.options.allowMixed) {
default:
case types_1.Severity.WARN:
logSettings_1.logger.warn('Implicitly setting "Mixed" is not allowed! (%s, %s)', name, key);
case types_1.Severity.ALLOW:
data_1.schemas.get(name)[key] = Object.assign(Object.assign(Object.assign({}, data_1.schemas.get(name)[key]), options), { type: mongoose.Schema.Types.Mixed });
return;
case types_1.Severity.ERROR:
throw new TypeError(util_1.format('Implicitly setting "Mixed" is not allowed! (%s, %s)', name, key));
}
}
utils.warnMixed(target, key);
data_1.schemas.get(name)[key] = Object.assign(Object.assign(Object.assign({}, data_1.schemas.get(name)[key]), options), { type: mongoose.Schema.Types.Mixed });
return;
}

@@ -229,6 +221,6 @@ switch (whatis) {

if ('items' in options) {
logSettings_1.logger.warn(new Error('You might not want to use option "items" in a @prop, use @arrayProp'));
logSettings_1.logger.warn(new Error(util_1.format('You might not want to use option "items" in a @prop, use @arrayProp (%s.%s)', utils.getName(target), key)));
}
if ('of' in options) {
logSettings_1.logger.warn(new Error('You might not want to use option "of" in a @prop, use @mapProp'));
logSettings_1.logger.warn(new Error(util_1.format('You might not want to use option "of" in a @prop, use @mapProp (%s.%s)', utils.getName(target), key)));
}

@@ -255,3 +247,3 @@ }

if ('items' in options) {
logSettings_1.logger.warn(new Error('You might not want to use option "items" in a @mapProp, use @arrayProp'));
logSettings_1.logger.warn(new Error(util_1.format('You might not want to use option "items" in a @mapProp, use @arrayProp (%s.%s)', utils.getName(target), key)));
}

@@ -277,3 +269,3 @@ baseProp({

if ('of' in options) {
logSettings_1.logger.warn(new Error('You might not want to use option "of" in a @arrayProp, use @mapProp'));
logSettings_1.logger.warn(new Error(util_1.format('You might not want to use option "of" in a @arrayProp, use @mapProp (%s.%s)', utils.getName(target), key)));
}

@@ -305,2 +297,2 @@ if ('items' in options) {

exports.arrayProp = arrayProp;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJvcC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9wcm9wLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUFBLHFDQUFxQztBQUVyQywrQkFBaUQ7QUFDakQsb0RBQXFEO0FBQ3JELDBDQUFvRDtBQUNwRCw4Q0FPMkI7QUFFM0IsMENBQTBDO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UFFLEtBQUssQ0FBQyxPQUFPLENBQUMsTUFBTSxDQUFDLEVBQUUsR0FBRyxDQUFDLENBQ2xILENBQUMsQ0FBQztTQUNKO1FBRUQsSUFBSSxPQUFPLElBQUksT0FBTyxFQUFFO1lBQ3RCLE9BQU8sT0FBTyxDQUFDLEtBQUssQ0FBQztTQUN0QjtRQUNELElBQUksVUFBVSxJQUFJLE9BQU8sRUFBRTtZQUN6QixPQUFPLENBQUMsR0FBRyxHQUFHLE9BQU8sQ0FBQyxRQUFRLENBQUM7WUFDL0IsT0FBTyxPQUFPLENBQUMsUUFBUSxDQUFDO1NBQ3pCO1FBQ0QsSUFBSSxjQUFjLElBQUksT0FBTyxFQUFFO1lBQzdCLE9BQU8sQ0FBQyxPQUFPLEdBQUcsT0FBTyxDQUFDLFlBQVksQ0FBQztZQUN2QyxPQUFPLE9BQU8sQ0FBQyxZQUFZLENBQUM7U0FDN0I7UUFDRCxJQUFJLGNBQWMsSUFBSSxPQUFPLEVBQUU7WUFDN0IsT0FBTyxDQUFDLE9BQU8sR0FBRyxPQUFPLENBQUMsWUFBWSxDQUFDO1lBQ3ZDLE9BQU8sT0FBTyxDQUFDLFlBQVksQ0FBQztTQUM3QjtRQUVELFFBQVEsQ0FBQztZQUNQLElBQUk7WUFDSixHQUFHO1lBQ0gsV0FBVyxFQUFFLE9BQU87WUFDcEIsTUFBTTtZQUNOLE1BQU0sRUFBRSxnQkFBUSxDQUFDLEtBQUs7U0FDdkIsQ0FBQyxDQUFDO0lBQ0wsQ0FBQyxDQUFDO0FBQ0osQ0FBQztBQWxDRCw4QkFrQ0MifQ==

@@ -23,5 +23,5 @@ import * as mongoose from 'mongoose';

/** @deprecated */
getModelForClass<T, U extends AnyParamConstructor<T>>(cl: U, settings?: any): ReturnModelType<U, unknown>;
getModelForClass<T, U extends AnyParamConstructor<T>>(cl: U, settings?: any): any;
/** @deprecated */
setModelForClass<T, U extends AnyParamConstructor<T>>(cl: U, settings?: any): ReturnModelType<U, unknown>;
setModelForClass<T, U extends AnyParamConstructor<T>>(cl: U, settings?: any): any;
/** @deprecated */

@@ -51,3 +51,3 @@ buildSchema<T, U extends AnyParamConstructor<T>>(cl: U): mongoose.Schema<U>;

*/
export declare function setModelForClass<T, U extends AnyParamConstructor<T>>(cl: U): ReturnModelType<U, unknown>;
export declare function setModelForClass<T, U extends AnyParamConstructor<T>>(cl: U): any;
/**

@@ -54,0 +54,0 @@ * Generates a Mongoose schema out of class props, iterating through all parents

@@ -46,4 +46,3 @@ "use strict";

getModelForClass(cl, settings) {
utils_1.assignMetadata(constants_1.DecoratorKeys.ModelOptions, settings, cl);
return util_1.deprecate(getModelForClass, 'Typegoose Class is Deprecated!')(cl);
return util_1.deprecate(getModelForClass.bind(undefined, cl, settings), 'Typegoose Class is Deprecated!')(cl);
}

@@ -53,4 +52,3 @@ /* istanbul ignore next */

setModelForClass(cl, settings) {
utils_1.assignMetadata(constants_1.DecoratorKeys.ModelOptions, settings, cl);
return util_1.deprecate(setModelForClass, 'Typegoose Class is Deprecated!')(cl);
return util_1.deprecate(getModelForClass.bind(undefined, cl, settings), 'Typegoose Class is Deprecated!')(cl);
}

@@ -81,3 +79,4 @@ /* istanbul ignore next */

}
const roptions = utils_1.mergeMetadata(constants_1.DecoratorKeys.ModelOptions, options || {}, cl);
options = typeof options === 'object' ? options : {};
const roptions = utils_1.mergeMetadata(constants_1.DecoratorKeys.ModelOptions, options, cl);
const name = utils_1.getName(cl);

@@ -111,3 +110,3 @@ if (data_1.models.get(name)) {

function setModelForClass(cl) {
return util_1.deprecate(getModelForClass(cl), 'setModelForClass is deprecated, please use getModelForClasse (see README#Migrate to 6.0.0)');
return util_1.deprecate(getModelForClass.bind(undefined, cl), 'setModelForClass is deprecated, please use getModelForClass (see README#Migrate to 6.0.0)');
}

@@ -235,2 +234,2 @@ exports.setModelForClass = setModelForClass;

exports.getDiscriminatorModelForClass = getDiscriminatorModelForClass;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjoz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sQ0FBQyxHQUFHLENBQUMsSUFBSSxDQUFDLEVBQUU7UUFDcEIsT0FBTyxhQUFNLENBQUMsR0FBRyxDQUFDLElBQUksQ0FBMEIsQ0FBQztLQUNsRDtJQUNELE1BQU0sR0FBRyxHQUFHLFdBQVcsQ0FBQyxFQUFFLENBQXdDLENBQUM7SUFFbkUsTUFBTSxnQkFBZ0IsR0FBRyxHQUFHLENBQUMsR0FBRyxDQUFDLGtCQUFrQixDQUFDLENBQUM7SUFDckQsSUFBSSxHQUFHLENBQUMsSUFBSSxDQUFDLGdCQUFnQixDQUFDLEVBQUU7UUFDOUIsR0FBRyxDQUFDLEtBQUssQ0FBQyxnQkFBZ0IsQ0FBQyxDQUFDLE9BQU8sQ0FBQyx1QkFBdUIsR0FBRyxJQUFJLENBQUM7S0FDcEU7SUFFRCxNQUFNLEtBQUssR0FBRyxJQUFJLENBQUMsYUFBYSxDQUFDLElBQUksRUFBRSxHQUFHLEVBQUUsRUFBRSxDQUFDLENBQUMsQ0FBQyxFQUFFLENBQUMsQ0FBQyxDQUFDLElBQUksQ0FBQyxDQUFDO0lBRTVELE9BQU8sbUJBQW1CLENBQUMsS0FBSyxFQUFFLEVBQUUsQ0FBQyxDQUFDO0FBQ3hDLENBQUM7QUFuQkQsc0VBbUJDIn0=

@@ -325,1 +325,71 @@ /// <reference types="node" />

}
export interface IndexOptions<T> {
/**
* Mongoose-specific syntactic sugar, uses ms to convert
* expires option into seconds for the expireAfterSeconds in the above link.
*/
expires?: string;
/**
* Creates an unique index.
*/
unique?: boolean;
/**
* Creates a sparse index.
*/
sparse?: boolean;
/**
* Creates the index in the background, yielding whenever possible.
*/
background?: boolean;
/**
* A unique index cannot be created on a key that has pre-existing duplicate values.
* If you would like to create the index anyway, keeping the first document the database indexes and
* deleting all subsequent documents that have duplicate value
*/
dropDups?: boolean;
/**
* For geo spatial indexes set the lower bound for the co-ordinates.
*/
min?: number;
/**
* For geo spatial indexes set the high bound for the co-ordinates.
*/
max?: number;
/**
* Specify the format version of the indexes.
*/
v?: number;
/**
* Allows you to expire data on indexes applied to a data (MongoDB 2.2 or higher)
*/
expireAfterSeconds?: number;
/**
* Override the auto generated index name (useful if the resulting name is larger than 128 bytes)
*/
name?: string;
/**
* Creates a partial index based on the given filter object (MongoDB 3.2 or higher)
*/
partialFilterExpression?: any;
collation?: object;
default_language?: string;
lowercase?: boolean;
uppercase?: boolean;
trim?: boolean;
weights?: {
[P in keyof Partial<T>]: number;
};
}
/**
* Used as a Type for the return of getMetadata
* @example
* ```ts
* const indices: IIndexArray[] = Reflect.getMetadata(DecoratorKeys.Index, target) || [];
* ```
*/
export interface IIndexArray<T> {
fields: {
[key: string]: any;
};
options: IndexOptions<T>;
}
{
"name": "@typegoose/typegoose",
"version": "6.1.0-10",
"version": "6.1.0-11",
"description": "Define Mongoose models using TypeScript classes",

@@ -74,3 +74,13 @@ "main": "lib/typegoose.js",

"access": "public"
}
},
"keywords": [
"typegoose",
"mongoose",
"orm",
"mongodb",
"class",
"model",
"schema",
"odm"
]
}
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