Skip to content

Commit 194b2ac

Browse files
Simplified the YAML parser, now that the YAML object isn't exported
1 parent b4c7389 commit 194b2ac

File tree

2 files changed

+2
-36
lines changed

2 files changed

+2
-36
lines changed

lib/parsers/yaml.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
"use strict";
22

3-
const YAML = require("../util/yaml");
43
const { ParserError } = require("../util/errors");
4+
const yaml = require("js-yaml");
55

66
module.exports = {
77
/**
@@ -45,7 +45,7 @@ module.exports = {
4545

4646
if (typeof data === "string") {
4747
try {
48-
return YAML.parse(data);
48+
return yaml.safeLoad(data);
4949
}
5050
catch (e) {
5151
throw new ParserError(e.message, file.url);

lib/util/yaml.js

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)