From df741a3d95bc8221aa118bc822aff53900653ec5 Mon Sep 17 00:00:00 2001 From: Oliverpool Date: Fri, 18 Dec 2015 09:34:13 +0100 Subject: [PATCH] Delete key only if existent --- patacrep/songbook/__main__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/patacrep/songbook/__main__.py b/patacrep/songbook/__main__.py index 9daff597..587b1d8d 100644 --- a/patacrep/songbook/__main__.py +++ b/patacrep/songbook/__main__.py @@ -172,10 +172,10 @@ def main(): ) for path in songbook['book']['datadir'] ] + del songbook['book']['datadir'] + # Default value datadirs.append(os.path.dirname(os.path.abspath(songbook_path))) - - del songbook['book']['datadir'] songbook['_datadir'] = datadirs songbook['_cache'] = options.cache[0]