瀏覽代碼

Forgot we can't iterate over cursor.execute()...

pull/24/head
Ben Kurtovic 12 年之前
父節點
當前提交
4003711724
共有 1 個檔案被更改,包括 2 行新增1 行删除
  1. +2
    -1
      pages/copyvios.mako

+ 2
- 1
pages/copyvios.mako 查看文件

@@ -190,7 +190,8 @@

def synchronize_sites_with_db(cursor, updates, q_list, q_rmv, q_update):
removals = []
for site in cursor.execute(q_list):
cursor.execute(q_list)
for site in cursor:
updates.remove(site) if site in updates else removals.append(site)
cursor.executemany(q_rmv, removals)
cursor.executemany(q_update, updates)


Loading…
取消
儲存