mirror of
https://github.com/crate-ci/typos.git
synced 2024-11-24 18:10:56 -05:00
fix(config): Don't overwrite locale and tokenizer config
This was broken in #882
This commit is contained in:
parent
935271f020
commit
0c11a25f73
1 changed files with 7 additions and 4 deletions
|
@ -227,13 +227,16 @@ impl<'s> ConfigEngine<'s> {
|
||||||
let check_filename = engine.check_filename();
|
let check_filename = engine.check_filename();
|
||||||
let check_file = engine.check_file();
|
let check_file = engine.check_file();
|
||||||
let crate::config::EngineConfig {
|
let crate::config::EngineConfig {
|
||||||
tokenizer: mut tokenizer_config,
|
tokenizer: tokenizer_user_config,
|
||||||
dict: mut dict_config,
|
dict: dict_user_config,
|
||||||
extend_ignore_re,
|
extend_ignore_re,
|
||||||
..
|
..
|
||||||
} = engine;
|
} = engine;
|
||||||
tokenizer_config.update(&crate::config::TokenizerConfig::from_defaults());
|
|
||||||
dict_config.update(&crate::config::DictConfig::from_defaults());
|
let mut tokenizer_config = crate::config::TokenizerConfig::from_defaults();
|
||||||
|
tokenizer_config.update(&tokenizer_user_config);
|
||||||
|
let mut dict_config = crate::config::DictConfig::from_defaults();
|
||||||
|
dict_config.update(&dict_user_config);
|
||||||
|
|
||||||
if !tokenizer_config.ignore_hex() {
|
if !tokenizer_config.ignore_hex() {
|
||||||
log::warn!("`ignore-hex` is deprecated");
|
log::warn!("`ignore-hex` is deprecated");
|
||||||
|
|
Loading…
Reference in a new issue