瀏覽代碼

Fix bug when page contains unicode.

pull/8/merge
Ben Kurtovic 12 年之前
父節點
當前提交
7970fab9f6
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. +1
    -1
      tasks/afc_copyvios.py

+ 1
- 1
tasks/afc_copyvios.py 查看文件

@@ -154,7 +154,7 @@ class AFCCopyvios(Task):
config, which is ``False`` by default.
"""
pageid = page.pageid
hash = sha256(page.get()).hexdigest()
hash = sha256(page.get().encode("utf8")).hexdigest()
query1 = "SELECT 1 FROM cache WHERE cache_id = ?"
query2 = "DELETE FROM cache WHERE cache_id = ?"
query3 = "INSERT INTO cache VALUES (?, ?, ?, CURRENT_TIMESTAMP, ?, ?)"


Loading…
取消
儲存