Browse Source

If a string is passed in BaseRepo.get_walker we turn it into a one item list instead of iterating over the string itself

Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
Alberto Ruiz 11 years ago
parent
commit
1a44d171e0
1 changed files with 2 additions and 0 deletions
  1. 2 0
      dulwich/repo.py

+ 2 - 0
dulwich/repo.py

@@ -1081,6 +1081,8 @@ class BaseRepo(object):
         from dulwich.walk import Walker
         if include is None:
             include = [self.head()]
+        if isinstance(include, str):
+            include = [include]
         return Walker(self.object_store, include, *args, **kwargs)
 
     def revision_history(self, head):