changeset 31743:068b06b43cdf

largefiles: make copytostore() accept only changectx as the 2nd argument (API) As the name describes, the 2nd argument 'revorctx' of copytostore() can accept non-changectx value, for historical reason, But, since 10561eb97c7f, copyalltostore(), the only one copytostore() client in Mercurial source tree, always passes changectx as 'revorctx'. Therefore, it is reasonable to make copytostore() accept only changectx as the 2nd argument, now.
author FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
date Sat, 01 Apr 2017 02:32:48 +0900
parents c03af6b44846
children 4e446d31a744
files hgext/largefiles/lfutil.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/largefiles/lfutil.py	Sat Apr 01 02:32:48 2017 +0900
+++ b/hgext/largefiles/lfutil.py	Sat Apr 01 02:32:48 2017 +0900
@@ -245,9 +245,9 @@
         return False
     return True
 
-def copytostore(repo, revorctx, file, fstandin):
+def copytostore(repo, ctx, file, fstandin):
     wvfs = repo.wvfs
-    hash = readasstandin(repo[revorctx][fstandin])
+    hash = readasstandin(ctx[fstandin])
     if instore(repo, hash):
         return
     if wvfs.exists(file):