Commits

Steve Borho committed dd46dd1

guess: localrepo functions were moved to workingctx in hg-1.6

localrepo.remove() and copy() were moved to the workingctx in Mercurial
in changeset a1aad8333864 (three weeks ago).

Closes #1345

Comments (0)

Files changed (1)

tortoisehg/hgtk/guess.py

     def accept_match(self):
         'User pressed "accept match" button'
         hglib.invalidaterepo(self.repo)
+        wctx = self.repo[None]
         canmodel, upaths = self.cantree.get_selection().get_selected_rows()
         for path in upaths:
             row = canmodel[path]
                 continue
             if not os.path.exists(self.repo.wjoin(src)):
                 # Mark missing rename source as removed
-                self.repo.remove([src])
-            self.repo.copy(src, dest)
+                wctx.remove([src])
+            wctx.copy(src, dest)
             shlib.shell_notify([self.repo.wjoin(src), self.repo.wjoin(dest)])
             if self.notify_func:
                 self.notify_func()