diff options
author | Christopher Allan Webber <cwebber@dustycloud.org> | 2011-06-20 21:02:46 -0500 |
---|---|---|
committer | Christopher Allan Webber <cwebber@dustycloud.org> | 2011-06-20 21:02:46 -0500 |
commit | a2c37d0a78f939ee208225840f83a90fd698aedf (patch) | |
tree | 666883e2d20e41aa82cd554ddadf6a5db82ed744 | |
parent | 826888465397ef8915b3a4a538ad26dff08d2625 (diff) | |
download | mediagoblin-a2c37d0a78f939ee208225840f83a90fd698aedf.tar.lz mediagoblin-a2c37d0a78f939ee208225840f83a90fd698aedf.tar.xz mediagoblin-a2c37d0a78f939ee208225840f83a90fd698aedf.zip |
Only migrate to description_html if description also exists.
-rw-r--r-- | mediagoblin/db/migrations.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mediagoblin/db/migrations.py b/mediagoblin/db/migrations.py index b87988fe..aacbf079 100644 --- a/mediagoblin/db/migrations.py +++ b/mediagoblin/db/migrations.py @@ -40,7 +40,8 @@ class MediaEntryMigration(DocumentMigration): Now that we can have rich descriptions via Markdown, we should update all existing entries to record the rich description versions. """ - self.target = {'description_html': {'$exists': False}} + self.target = {'description_html': {'$exists': False}, + 'description': {'$exists': True}} if not self.status: for doc in self.collection.find(self.target): |