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

raml-typesystem

Package Overview
Dependencies
Maintainers
2
Versions
95
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

raml-typesystem - npm Package Compare versions

Comparing version 0.0.49 to 0.0.50

19

dist/src/restrictions.js

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

if (this._type.isSubTypeOf(ts.UNKNOWN) || this._type.isSubTypeOf(ts.RECURRENT)) {
var p = new typesystem_2.Status(typesystem_2.Status.ERROR, 0, "property " + this.propId() + " refers to unknown type " + this._type.name(), this);
var actualUnknown = actualUnknownType(this._type);
var p = new typesystem_2.Status(typesystem_2.Status.ERROR, 0, "property " + this.propId() + " refers to unknown type " + actualUnknown.name(), this);
p.setValidationPath({ name: this.propId(), child: { name: "type" } });

@@ -1293,2 +1294,18 @@ return p;

exports.optimize = optimize;
function actualUnknownType(t) {
if (!t.isSubTypeOf(ts.UNKNOWN)) {
return null;
}
if (t.name() != null) {
return t;
}
for (var _i = 0, _a = t.superTypes(); _i < _a.length; _i++) {
var st = _a[_i];
var ust = actualUnknownType(st);
if (ust != null) {
return ust;
}
}
return t;
}
//# sourceMappingURL=restrictions.js.map

2

package.json
{
"name": "raml-typesystem",
"version": "0.0.49",
"version": "0.0.50",
"main": "dist/src/index.js",

@@ -5,0 +5,0 @@ "scripts": {

@@ -79,3 +79,4 @@ /// <reference path="../typings/main.d.ts" />

if (this._type.isSubTypeOf(ts.UNKNOWN)||this._type.isSubTypeOf(ts.RECURRENT)){
var p= new Status(Status.ERROR,0,"property "+this.propId()+" refers to unknown type "+this._type.name(),this)
var actualUnknown = actualUnknownType(this._type);
var p= new Status(Status.ERROR,0,"property "+this.propId()+" refers to unknown type "+actualUnknown.name(),this)
p.setValidationPath({name: this.propId(), child: { name: "type"}})

@@ -1315,2 +1316,19 @@ return p;

return optimized;
}
function actualUnknownType(t:AbstractType):AbstractType{
if(!t.isSubTypeOf(ts.UNKNOWN)){
return null;
}
if(t.name()!=null){
return t;
}
for(var st of t.superTypes()){
var ust = actualUnknownType(st);
if(ust!=null){
return ust;
}
}
return t;
}

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