2e8b8ba8e49e7bde133fea509fb04f55ae42575a
[yaffs-website] / node_modules / grunt-legacy-util / node_modules / lodash / valuesIn.js
1 var baseValues = require('./_baseValues'),
2     keysIn = require('./keysIn');
3
4 /**
5  * Creates an array of the own and inherited enumerable property values of `object`.
6  *
7  * **Note:** Non-object values are coerced to objects.
8  *
9  * @static
10  * @memberOf _
11  * @category Object
12  * @param {Object} object The object to query.
13  * @returns {Array} Returns the array of property values.
14  * @example
15  *
16  * function Foo() {
17  *   this.a = 1;
18  *   this.b = 2;
19  * }
20  *
21  * Foo.prototype.c = 3;
22  *
23  * _.valuesIn(new Foo);
24  * // => [1, 2, 3] (iteration order is not guaranteed)
25  */
26 function valuesIn(object) {
27   return object == null ? baseValues(object, keysIn(object)) : [];
28 }
29
30 module.exports = valuesIn;