Patchwork D6016: memfilefromctx: migrate to new method for getting copy info

login
register
mail settings
Submitter phabricator
Date Feb. 24, 2019, 8:24 a.m.
Message ID <2f840f3c27e6e4012474c16b10fc0c68@localhost.localdomain>
Download mbox | patch
Permalink /patch/38904/
State Not Applicable
Headers show

Comments

phabricator - Feb. 24, 2019, 8:24 a.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG322ce0bca19d: memfilefromctx: migrate to new method for getting copy info (authored by martinvonz, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D6016?vs=14204&id=14219

REVISION DETAIL
  https://phab.mercurial-scm.org/D6016

AFFECTED FILES
  mercurial/context.py

CHANGE DETAILS




To: martinvonz, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/mercurial/context.py b/mercurial/context.py
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -2234,9 +2234,7 @@ 
     """
     def getfilectx(repo, memctx, path):
         fctx = ctx[path]
-        copied = fctx.renamed()
-        if copied:
-            copied = copied[0]
+        copied = fctx.copysource()
         return memfilectx(repo, memctx, path, fctx.data(),
                           islink=fctx.islink(), isexec=fctx.isexec(),
                           copied=copied)