Skip to content

Commit

Permalink
gpodder.model: Fix problems with migrated databases
Browse files Browse the repository at this point in the history
I'm finally migrating from gpodder 2 to 3, and when starting up gpodder3
after running the migration, I ran into the following uncaught exception
(which aborted gpodder):

TypeError: coercing to Unicode: need string or buffer, NoneType found
  • Loading branch information
dovf authored and thp committed Jan 30, 2014
1 parent b325c7d commit fa2104d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/gpodder/model.py
Expand Up @@ -818,7 +818,7 @@ def check_download_folder(self):
for episode in self.get_episodes(gpodder.STATE_DOWNLOADED):
if episode.was_downloaded():
filename = episode.local_filename(create=False)
if not os.path.exists(filename):
if filename is not None and not os.path.exists(filename):
# File has been deleted by the user - simulate a
# delete event (also marks the episode as deleted)
logger.debug('Episode deleted: %s', filename)
Expand Down

0 comments on commit fa2104d

Please sign in to comment.