From 11d91e245194cd9a2e44b81b2b3c62514596c578 Mon Sep 17 00:00:00 2001 From: Yobmod Date: Sun, 16 May 2021 18:10:05 +0100 Subject: Add remaining types to IndexFile ._preprocess_add_items() to .diff() --- git/index/base.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'git/index/base.py') diff --git a/git/index/base.py b/git/index/base.py index f2ba71e0..cf7fafef 100644 --- a/git/index/base.py +++ b/git/index/base.py @@ -586,7 +586,8 @@ class IndexFile(LazyMixin, diff.Diffable, Serializable): raise ValueError("Absolute path %r is not in git repository at %r" % (path, self.repo.working_tree_dir)) return os.path.relpath(path, self.repo.working_tree_dir) - def _preprocess_add_items(self, items): + def _preprocess_add_items(self, items: Sequence[Union[PathLike, Blob, BaseIndexEntry, Submodule]] + ) -> Tuple[List[PathLike], List[BaseIndexEntry]]: """ Split the items into two lists of path strings and BaseEntries. """ paths = [] entries = [] -- cgit v1.2.1