Skip to content

Commit

Permalink
Merge pull request #41 from thevilx/HotFix
Browse files Browse the repository at this point in the history
remove dbg!() & finished find_capital todo
  • Loading branch information
ali77gh authored Jan 17, 2024
2 parents eed403c + b253fc8 commit ff42ac4
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
1 change: 0 additions & 1 deletion src/commas/add_commas.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ pub fn add_commas_mut(str_mut: &mut String) {
.position(|c| c == '.')
.unwrap_or_else(|| str_mut.chars().filter(comma_less).count());

dbg!(end);
let mut i = 0;
while i < end {
if (end - i) % 3 == 0 && i != 0 {
Expand Down
10 changes: 4 additions & 6 deletions src/find_capital_by_province/mod.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
use crate::persian_chars::to_persian_chars;

/// Returns the capital name of province you enter
pub fn find_capital_by_province<S>(inp: S) -> Option<String>
where
S: Into<String>,
{
// TODO: Accept `AsRef<str>` and remove the following `inp.into()`
let r = match to_persian_chars(inp.into()).as_str() {
pub fn find_capital_by_province(input: impl AsRef<str>) -> Option<String> {
let input = input.as_ref();

let r = match to_persian_chars(input).as_str() {
"آذربایجان شرقی" => "تبریز",
"آذربایجان غربی" => "ارومیه",
"اردبیل" => "اردبیل",
Expand Down
1 change: 0 additions & 1 deletion src/verity_card_number/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ pub fn verify_card_number(digits: impl AsRef<str>) -> Result<(), VerifyCardNumbe
};
}

dbg!(&sum);
if sum % 10 == 0 {
Ok(())
} else {
Expand Down

0 comments on commit ff42ac4

Please sign in to comment.