Skip to content

Commit

Permalink
remove IBAN validation
Browse files Browse the repository at this point in the history
  • Loading branch information
AnthonyBuisset committed Jan 4, 2024
1 parent d23f40f commit 7e04c93
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 25 deletions.
11 changes: 0 additions & 11 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/tests/update_user_payout_info_it.rs
Original file line number Diff line number Diff line change
Expand Up @@ -682,7 +682,7 @@ impl<'a> Test<'a> {
.await;

// Then
assert_eq!(response.status(), Status::UnprocessableEntity);
assert_eq!(response.status(), Status::Ok);

Ok(())
}
Expand Down
1 change: 0 additions & 1 deletion common/domain/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ uuid08 = { package = "uuid", version = "0.8", default_features = false, features

rust_decimal = "1.26.1"
rusty-money = { version = "0.4.1", features = ["iso", "crypto"] }
iban_validate = { version = "4.0.1", features = ["serde"] }
hex = "0.4.3"
starknet-ff = "0.3.4"

Expand Down
15 changes: 3 additions & 12 deletions common/domain/src/value_objects/iban.rs
Original file line number Diff line number Diff line change
@@ -1,16 +1,7 @@
use std::fmt::Display;

use derive_more::{From, FromStr, Into};
use iban::IbanLike;
use derive_more::{Display, From, FromStr, Into};
use serde_with::{DeserializeFromStr, SerializeDisplay};

#[derive(
Debug, Clone, PartialEq, Eq, From, Into, FromStr, SerializeDisplay, DeserializeFromStr,
Debug, Clone, PartialEq, Eq, From, Into, FromStr, Display, SerializeDisplay, DeserializeFromStr,

Check warning on line 5 in common/domain/src/value_objects/iban.rs

View check run for this annotation

Codecov / codecov/patch

common/domain/src/value_objects/iban.rs#L5

Added line #L5 was not covered by tests
)]
pub struct Iban(iban::Iban);

impl Display for Iban {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{}", self.0.electronic_str())
}
}
pub struct Iban(String);

0 comments on commit 7e04c93

Please sign in to comment.