Permalink
Browse files

bugfix: travel tree when search in trees

  • Loading branch information...
1 parent 3251091 commit ad1d63413645ac588cf02ec1e693083ded5b9017 @dodo dodo committed May 21, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/git/tree.js
View
@@ -122,7 +122,7 @@ Tree.prototype.find = function(file) {
var paths = file.split('/');
paths.length > 0 && paths[paths.length - 1] == '' ? paths.pop() : null;
return paths.map(function(x) {
- return self.find(x);
+ return self && (self = self.find(x));
});
} else {
var results = self.contents.filter(function(c) {

0 comments on commit ad1d634

Please sign in to comment.