lib/dirio.js
function _jsonLoaded(callback, err, data) {
  if (err) return callback(err);
  var parsed;
  try {
    parsed = JSON.parse(data);
  } catch(jerr) {
    return callback(jerr);
  }
  callback(null, parsed);
}
function _jsonLoaded(callback, err, data) {
  if (err) return callback(err);
  var parsed;
  try {
    parsed = JSON.parse(data);
  } catch(jerr) {
    return callback(jerr);
  }
  callback(null, parsed);
}
function _jsonLoaded ( callback , err , data ) { if ( err ) return callback ( err ) ; var parsed ; try { parsed = JSON . parse ( data ) ; } catch ( jerr ) { return callback ( jerr ) ; } callback ( null , parsed ) ; }
Parses content of a json file.
@param {Function} callback - Callback that expects a possible error
and the result.
@param {*} err - Possible error passed by caller.
@param {String} data - Content of the file.
Parses content of a json file .