Comparing version
@@ -36,6 +36,6 @@ 'use strict'; | ||
if (id && id.length > 1 && subSchemas) { | ||
if (id && subSchemas) { | ||
refschema = subSchemas[id] || subSchemas[id.substr(0, id.length - 1)]; | ||
} | ||
else { | ||
if (!refschema) { | ||
refschema = schema; | ||
@@ -42,0 +42,0 @@ } |
{ | ||
"name": "enjoi", | ||
"version": "0.2.1", | ||
"version": "0.2.2", | ||
"description": "Converts json-schema to Joi schema for validation.", | ||
@@ -5,0 +5,0 @@ "main": "lib/enjoi.js", |
10090
-0.06%