diff --git a/pandora/item/models.py b/pandora/item/models.py index 0d9ed063d..bfbc46946 100644 --- a/pandora/item/models.py +++ b/pandora/item/models.py @@ -410,6 +410,8 @@ class Item(models.Model): def delete_files(self): path = os.path.join(settings.MEDIA_ROOT, self.path()) + if isinstance(path, unicode): + path = path.encode('utf-8') if os.path.exists(path): shutil.rmtree(path)