Files
control-pane/public/novnc/node_modules/po2json/lib/parseFileSync.js
Charlie Root 58f2e80eb5 update
2022-07-31 09:56:11 +00:00

15 lines
344 B
JavaScript

var fs = require("fs");
/**
* Synchronously parse a PO file to JSON
*
* @param {String} fileName - File name
* @param {Object} [options]
* @return {Object|String} Translation JSON
*/
module.exports = function(fileName, options) {
var data = fs.readFileSync(fs.realpathSync(fileName));
return require("./parse")( data, options );
};