fix: fix a bug in previous commit
Fk Rust
This commit is contained in:
parent
8ed238455d
commit
093503cd97
@ -521,9 +521,9 @@ pub async fn analyze_card_subprocess(
|
|||||||
|
|
||||||
async fn execute_analyze_drop(image: DynamicImage, count: u32) -> Result<DroppedCard, String> {
|
async fn execute_analyze_drop(image: DynamicImage, count: u32) -> Result<DroppedCard, String> {
|
||||||
let config = CONFIG.get().unwrap();
|
let config = CONFIG.get().unwrap();
|
||||||
match config.tesseract.backend {
|
match config.tesseract.backend.as_str() {
|
||||||
String::from("libtesseract") => analyze_card_libtesseract(image, count).await,
|
"libtesseract" => analyze_card_libtesseract(image, count).await,
|
||||||
String::from("subprocess") => analyze_card_subprocess(image, count).await,
|
"subprocess" => analyze_card_subprocess(image, count).await,
|
||||||
_ => {
|
_ => {
|
||||||
panic!("Invalid Tesseract backend: {}", config.tesseract.backend);
|
panic!("Invalid Tesseract backend: {}", config.tesseract.backend);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user