mirror of
https://github.com/patarapolw/cjdic2.git
synced 2026-11-09 17:39:35 +00:00
fix for 0.1.1 commit create schema
This commit is contained in:
1 parent
8ee2fe950f
commit
54f3b699a9
3 files changed
+7
-7
No files matched your search
@@ -25,6 +25,7 @@ impl<'a> SearchDatabase<'a> {
|
||||
pub fn create_schema(&mut self) -> Result<(), CJDicError> {
|
||||
let tx = self.conn.transaction()?;
|
||||
SearchDatabase::create_schema_tx(&tx)?;
|
||||
tx.commit()?;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
@@ -594,7 +594,7 @@ impl YomitanWriter {
|
||||
|
||||
steps += entries.len();
|
||||
progress_callback(YomitanProgress {
|
||||
message: format!("Reading term banks"),
|
||||
message: format!("- Reading term banks"),
|
||||
current: bank_i,
|
||||
total: n_bank,
|
||||
steps,
|
||||
@@ -698,7 +698,7 @@ impl YomitanWriter {
|
||||
|
||||
steps += 1;
|
||||
progress_callback(YomitanProgress {
|
||||
message: format!("Reading term meta banks"),
|
||||
message: format!("- Reading term meta banks"),
|
||||
current: 0,
|
||||
total: 0,
|
||||
steps,
|
||||
@@ -741,7 +741,7 @@ impl YomitanWriter {
|
||||
|
||||
steps += 1;
|
||||
progress_callback(YomitanProgress {
|
||||
message: format!("Reading tag banks"),
|
||||
message: format!("- Reading tag banks"),
|
||||
current: 0,
|
||||
total: 0,
|
||||
steps,
|
||||
@@ -821,6 +821,9 @@ impl YomitanWriter {
|
||||
pub fn check_search_db(&mut self) -> Result<bool, CJDicError> {
|
||||
self.ensure_db_attached(DbChild::Search)?;
|
||||
|
||||
let mut search_db = SearchDatabase::new(&mut self.conn);
|
||||
search_db.create_schema()?;
|
||||
|
||||
let is_filled = self.conn.query_row(
|
||||
"
|
||||
SELECT
|
||||
|
||||
Reference in new issue
Block a user