← Back to team overview

dulwich-users team mailing list archive

[PATCH v2 2/6] pack.FilePackIndex: use self._file instead of file parameter

 

As the previous lines show, the file parameter could be unspecified. We
have already handled the case when it is unspecified, with the result in
self._file; so, use it instead of file.
---
 dulwich/pack.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dulwich/pack.py b/dulwich/pack.py
index 817e4ed..0654e67 100644
--- a/dulwich/pack.py
+++ b/dulwich/pack.py
@@ -346,7 +346,7 @@ class FilePackIndex(PackIndex):
         else:
             self._file = file
         if contents is None:
-            self._contents, self._size = _load_file_contents(file, size)
+            self._contents, self._size = _load_file_contents(self._file, size)
         else:
             self._contents, self._size = (contents, size)
 
-- 
1.7.3.2.msysgit.0




Follow ups

References