diff options
Diffstat (limited to 'node_modules/ajv/lib/dotjs')
| -rw-r--r-- | node_modules/ajv/lib/dotjs/format.js | 2 | ||||
| -rw-r--r-- | node_modules/ajv/lib/dotjs/ref.js | 4 | ||||
| -rw-r--r-- | node_modules/ajv/lib/dotjs/validate.js | 8 | 
3 files changed, 7 insertions, 7 deletions
diff --git a/node_modules/ajv/lib/dotjs/format.js b/node_modules/ajv/lib/dotjs/format.js index eb13371c1..68697f0de 100644 --- a/node_modules/ajv/lib/dotjs/format.js +++ b/node_modules/ajv/lib/dotjs/format.js @@ -55,7 +55,7 @@ module.exports = function generate_format(it, $keyword, $ruleType) {      var $format = it.formats[$schema];      if (!$format) {        if ($unknownFormats == 'ignore') { -        console.warn('unknown format "' + $schema + '" ignored in schema at path "' + it.errSchemaPath + '"'); +        it.logger.warn('unknown format "' + $schema + '" ignored in schema at path "' + it.errSchemaPath + '"');          if ($breakOnError) {            out += ' if (true) { ';          } diff --git a/node_modules/ajv/lib/dotjs/ref.js b/node_modules/ajv/lib/dotjs/ref.js index 6fb950546..a9d7bb909 100644 --- a/node_modules/ajv/lib/dotjs/ref.js +++ b/node_modules/ajv/lib/dotjs/ref.js @@ -22,7 +22,7 @@ module.exports = function generate_ref(it, $keyword, $ruleType) {      if ($refVal === undefined) {        var $message = it.MissingRefError.message(it.baseId, $schema);        if (it.opts.missingRefs == 'fail') { -        console.error($message); +        it.logger.error($message);          var $$outStack = $$outStack || [];          $$outStack.push(out);          out = ''; /* istanbul ignore else */ @@ -53,7 +53,7 @@ module.exports = function generate_ref(it, $keyword, $ruleType) {            out += ' if (false) { ';          }        } else if (it.opts.missingRefs == 'ignore') { -        console.warn($message); +        it.logger.warn($message);          if ($breakOnError) {            out += ' if (true) { ';          } diff --git a/node_modules/ajv/lib/dotjs/validate.js b/node_modules/ajv/lib/dotjs/validate.js index 0ff9eda42..5ff9beee7 100644 --- a/node_modules/ajv/lib/dotjs/validate.js +++ b/node_modules/ajv/lib/dotjs/validate.js @@ -123,7 +123,7 @@ module.exports = function generate_validate(it, $keyword, $ruleType) {        throw new Error('$ref: validation keywords used in schema at path "' + it.errSchemaPath + '" (see option extendRefs)');      } else if (it.opts.extendRefs !== true) {        $refKeywords = false; -      console.warn('$ref: keywords ignored in schema at path "' + it.errSchemaPath + '"'); +      it.logger.warn('$ref: keywords ignored in schema at path "' + it.errSchemaPath + '"');      }    }    if ($typeSchema) { @@ -281,7 +281,7 @@ module.exports = function generate_validate(it, $keyword, $ruleType) {      }    } else {      if (it.opts.v5 && it.schema.patternGroups) { -      console.warn('keyword "patternGroups" is deprecated and disabled. Use option patternGroups: true to enable.'); +      it.logger.warn('keyword "patternGroups" is deprecated and disabled. Use option patternGroups: true to enable.');      }      var arr2 = it.RULES;      if (arr2) { @@ -446,10 +446,10 @@ module.exports = function generate_validate(it, $keyword, $ruleType) {    }    function $shouldUseRule($rule) { -    return it.schema[$rule.keyword] !== undefined || ($rule.implements && $ruleImlementsSomeKeyword($rule)); +    return it.schema[$rule.keyword] !== undefined || ($rule.implements && $ruleImplementsSomeKeyword($rule));    } -  function $ruleImlementsSomeKeyword($rule) { +  function $ruleImplementsSomeKeyword($rule) {      var impl = $rule.implements;      for (var i = 0; i < impl.length; i++)        if (it.schema[impl[i]] !== undefined) return true;  | 
