refactor: move dictionary to util

This commit is contained in:
Theta-Dev 2022-10-10 12:22:27 +02:00
parent 0b9e486147
commit 1bc47b7c2d
5 changed files with 8 additions and 4 deletions

View file

@ -7,7 +7,7 @@ use rustypipe::timeago::TimeUnit;
use crate::util;
const TARGET_PATH: &str = "src/dictionary.rs";
const TARGET_PATH: &str = "src/util/dictionary.rs";
fn parse_tu(tu: &str) -> (u8, Option<TimeUnit>) {
static TU_PATTERN: Lazy<Regex> = Lazy::new(|| Regex::new(r"^(\d*)(\w?)$").unwrap());