From 835a39f17767e571df01192c07f1a3b3ba09ad82 Mon Sep 17 00:00:00 2001 From: Benjamin Bengfort Date: Sat, 23 Jun 2018 09:49:29 -0400 Subject: [PATCH] Fixed self.root duplication in export with catdir Fixes #95 --- baleen/export.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/baleen/export.py b/baleen/export.py index 0d25948..fa35191 100644 --- a/baleen/export.py +++ b/baleen/export.py @@ -208,7 +208,7 @@ def export(self, root=None, categories=None, level=SAFE): # Right now we will simply write them based on their object id. for post, category in tqdm(self.posts(), total=Post.objects.count(), unit="docs"): path = os.path.join( - self.root, catdir[category], "{}.{}".format(post.id, self.scheme) + catdir[category], "{}.{}".format(post.id, self.scheme) ) with codecs.open(path, 'w', encoding='utf-8') as f: