changeset 837:c24d2ea1361b

git_handler.import_git_commit: rename 'hg_renames' to 'renames' In upcoming patches we'll add other sources of renames.
author Siddharth Agarwal <sid0@fb.com>
date Mon, 01 Dec 2014 21:12:45 -0800
parents 6c9c40d9e9c1
children 6866ae460ee7
files hggit/git_handler.py
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hggit/git_handler.py
+++ b/hggit/git_handler.py
@@ -688,7 +688,9 @@
              commit.message, commit.extra)
         if hg_renames is None:
             # don't do any rename detection for now
-            hg_renames = {}
+            renames = {}
+        else:
+            renames = hg_renames
 
         gparents = map(self.map_hg_get, commit.parents)
 
@@ -814,7 +816,7 @@
                         data = util.serialize_hgsub(hgsub)
                 else:
                     data = self.git[sha].data
-                    copied_path = hg_renames.get(f)
+                    copied_path = renames.get(f)
                     e = self.convert_git_int_mode(mode)
             else:
                 # it's a converged file