1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

M #~: Add string conversion before write yaml files in fireedge (#1274)

This commit is contained in:
Sergio Betanzos 2021-06-04 13:57:44 +02:00 committed by GitHub
parent b1964b86d1
commit 695946153f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,7 +17,7 @@ const { dirname, basename } = require('path')
// eslint-disable-next-line node/no-deprecated-api
const { parse } = require('url')
const events = require('events')
const { Document, scalarOptions } = require('yaml')
const { Document, scalarOptions, stringify } = require('yaml')
const {
writeFileSync,
removeSync,
@ -156,7 +156,7 @@ const createYMLContent = (content = '') => {
} else {
doc.contents = undefined
}
rtn = doc
rtn = stringify(doc.contents)
} catch (error) {
messageTerminal(defaultError((error && error.message) || ''))
}