Dope'ily missed .count() on the query where we're counting
authorChristopher Allan Webber <cwebber@dustycloud.org>
Mon, 25 Feb 2013 22:35:05 +0000 (16:35 -0600)
committerChristopher Allan Webber <cwebber@dustycloud.org>
Mon, 25 Feb 2013 22:35:05 +0000 (16:35 -0600)
Thanks for catching, Elrond.

This commit sponsored by Graham King.  Thank you!

mediagoblin/db/migrations.py

index 3c997b94371430e2dfd1325681136bb8bb20e0be..05dc31ef11c2cbc0681b9f2df9b88f2a57877de3 100644 (file)
@@ -219,7 +219,7 @@ def mediaentry_new_slug_era(db):
         return db.execute(
             media_table.select(
                 media_table.c.uploader==uploader,
-                media_table.c.slug==slug)).first().tbl_row_count
+                media_table.c.slug==slug).count()).first().tbl_row_count
 
     def append_garbage_till_unique(row, new_slug):
         """