mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-09-12 05:48:57 +00:00
18 lines
355 B
JavaScript
18 lines
355 B
JavaScript
/**
|
|
Decode changes from a JS API to a config object
|
|
|
|
@param {Config} config
|
|
@param {Object} result: result from API
|
|
@return {Config}
|
|
*/
|
|
function decodeGlobal(config, result) {
|
|
var values = result.values;
|
|
|
|
delete values.generator;
|
|
delete values.output;
|
|
|
|
return config.updateValues(values);
|
|
}
|
|
|
|
module.exports = decodeGlobal;
|