aboutsummaryrefslogtreecommitdiff
path: root/chinese/ibus-array/files/patch-data_cin2sqlite.py
blob: becabcf8f2b1e466b236ebc47627ef042635c3f2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
--- data/cin2sqlite.py.orig	2026-06-05 09:16:48 UTC
+++ data/cin2sqlite.py
@@ -163,7 +163,7 @@ def array_updatedb(table_file, db_file="array.db"):
                 else:
                     # Write data to SQL Database
                     r = (str(REG_STACK[-1]) + "\t" + ln).split()
-                    cur.execute('INSERT INTO main (keys, ch, cat, cnt) VALUES ("' + r[1] + '", "' + r[2] + '", "' + r[0] + '", "0")') 
+                    cur.execute('INSERT INTO main (keys, ch, cat, cnt) VALUES (?, ?, ?, ?);', (r[1], r[2], r[0], '0'))
 
         f.close()
         con.commit()