(obj, path, bindFnToScope)
| 1622 | */ |
| 1623 | //TODO(misko): this function needs to be removed |
| 1624 | function getter(obj, path, bindFnToScope) { |
| 1625 | if (!path) return obj; |
| 1626 | var keys = path.split('.'); |
| 1627 | var key; |
| 1628 | var lastInstance = obj; |
| 1629 | var len = keys.length; |
| 1630 | |
| 1631 | for (var i = 0; i < len; i++) { |
| 1632 | key = keys[i]; |
| 1633 | if (obj) { |
| 1634 | obj = (lastInstance = obj)[key]; |
| 1635 | } |
| 1636 | } |
| 1637 | if (!bindFnToScope && isFunction(obj)) { |
| 1638 | return bind(lastInstance, obj); |
| 1639 | } |
| 1640 | return obj; |
| 1641 | } |
| 1642 | |
| 1643 | /** |
| 1644 | * Return the DOM siblings between the first and last node in the given array. |
no test coverage detected