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

modelsafe

Package Overview
Dependencies
Maintainers
3
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

modelsafe - npm Package Compare versions

Comparing version 0.7.0 to 0.7.1

4

CHANGELOG.md

@@ -0,1 +1,5 @@

# 0.7.1
* Catch errors during `hasModelOptions` in-case a non-object is given to `reflect-metadata`
# 0.7.0

@@ -2,0 +6,0 @@

@@ -58,3 +58,8 @@ "use strict";

function hasModelOptions(ctor) {
return Reflect.hasMetadata(exports.MODEL_OPTIONS_META_KEY, ctor.prototype);
try {
return Reflect.hasMetadata(exports.MODEL_OPTIONS_META_KEY, ctor.prototype);
}
catch (err) {
return false;
}
}

@@ -61,0 +66,0 @@ exports.hasModelOptions = hasModelOptions;

2

package.json
{
"name": "modelsafe",
"version": "0.7.0",
"version": "0.7.1",
"main": "dist/index.js",

@@ -5,0 +5,0 @@ "bugs": "https://github.com/creativecuriositystudio/modelsafe/issues",

@@ -60,3 +60,7 @@ /* tslint:disable:ban-types */

export function hasModelOptions(ctor: Function): boolean {
return Reflect.hasMetadata(MODEL_OPTIONS_META_KEY, ctor.prototype);
try {
return Reflect.hasMetadata(MODEL_OPTIONS_META_KEY, ctor.prototype);
} catch (err) {
return false;
}
}

@@ -63,0 +67,0 @@

Sorry, the diff of this file is not supported yet

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