awesome-cordova-plugins/dist/util.js
2015-11-29 16:30:15 -06:00

12 lines
233 B
JavaScript

function get(obj, path) {
for (var i = 0, path = path.split('.'), len = path.length; i < len; i++) {
if (!obj) {
return null;
}
obj = obj[path[i]];
}
return obj;
}
exports.get = get;
;