From 401c9a2d0ca7e103a1d17aa531a7addf62908467 Mon Sep 17 00:00:00 2001 From: deadc0de6 Date: Sat, 1 Sep 2018 19:45:33 +0200 Subject: [PATCH] fix bugs --- dotdrop/installer.py | 6 +++--- dotdrop/templategen.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dotdrop/installer.py b/dotdrop/installer.py index 1ca0595..b6528f1 100644 --- a/dotdrop/installer.py +++ b/dotdrop/installer.py @@ -62,10 +62,10 @@ class Installer: # and then symlink it as any other file # by udating src and dst + return [] - else: - # is not a template - self._link(src, dst) + # is not a template + return self._link(src, dst) def _link(self, src, dst): """set src as a link target of dst""" diff --git a/dotdrop/templategen.py b/dotdrop/templategen.py index a131961..85d1f45 100644 --- a/dotdrop/templategen.py +++ b/dotdrop/templategen.py @@ -92,7 +92,7 @@ class Templategen: return data.decode('utf-8', 'replace') def is_template(path): - if not os.path.exists(path): + if not os.path.isfile(path): return False with open(path, 'r') as f: data = f.read()