diff --git a/dotdrop/installer.py b/dotdrop/installer.py index 1b41ee4..88daa50 100644 --- a/dotdrop/installer.py +++ b/dotdrop/installer.py @@ -118,7 +118,6 @@ class Installer: srcs = [os.path.join(parent, child) for child in children] dsts = [os.path.join(dst, child) for child in children] - results = [] for i in range(len(children)): src = srcs[i] dst = dsts[i] @@ -141,9 +140,7 @@ class Installer: if len(result): actions = [] - results.append(result) - - return utils.flatten(results) + return (src, dst) def _link(self, src, dst, actions=[]): """set src as a link target of dst""" diff --git a/dotdrop/utils.py b/dotdrop/utils.py index e08af6e..bf3e979 100644 --- a/dotdrop/utils.py +++ b/dotdrop/utils.py @@ -113,11 +113,6 @@ def strip_home(path): return path -def flatten(a): - """flatten list""" - return functools.reduce(operator.iconcat, a, []) - - def must_ignore(paths, ignores, debug=False): """return true if any paths in list matches any ignore patterns""" if not ignores: