Fix HTML stripper accumulating data by remaking it on each usage
1 files changed, 3 insertions(+), 4 deletions(-)

M feed2maildir/converter.py
M feed2maildir/converter.py +3 -4
@@ 76,8 76,6 @@ Content-Type: text/plain
         self.db = os.path.expanduser(db)
         self.links = links
         self.strip = strip
-        if self.strip:
-            self.stripper = HTMLStripper()
 
         try: # to read the database
             with open(self.db, 'r') as f:

          
@@ 197,8 195,9 @@ Content-Type: text/plain
         desc = ''
         if not self.links:
             if self.strip:
-                self.stripper.feed(post.description)
-                desc = self.stripper.get_data()
+                stripper = HTMLStripper()
+                stripper.feed(post.description)
+                desc = stripper.get_data()
             else:
                 desc = post.description
         return self.TEMPLATE.format(updated,