Files
uTools-ProcessKiller/node_modules/lodash/internal/toObject.js
fofolee 9446af6b84 v0.0.2
2019-03-27 15:56:00 +08:00

15 lines
308 B
JavaScript

var isObject = require('../lang/isObject');
/**
* Converts `value` to an object if it's not one.
*
* @private
* @param {*} value The value to process.
* @returns {Object} Returns the object.
*/
function toObject(value) {
return isObject(value) ? value : Object(value);
}
module.exports = toObject;