Commit 67c09047 authored by Suhaimi Amir's avatar Suhaimi Amir

fix json parse

parent 3c574e39
Pipeline #1182 passed with stage
in 29 seconds
......@@ -19,9 +19,9 @@ exports.get = async (name) => {
logger.debug(`${JSON.stringify(ret.data)}`);
let config = ret.data.config;
if (ret.data.config.type === 'json') {
if (ret.data.type === 'json') {
config = JSON.parse(config);
} else if (ret.data.config.type === 'string') {
} else if (ret.data.type === 'string') {
config = String(config);
}
......
{
"name": "config",
"version": "1.0.4",
"version": "1.0.5",
"description": "Config getter/parser",
"main": "index.js",
"scripts": {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment