Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: change serde value to strict type in payment intent domain and diesel model #6393

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

hrithikesh026
Copy link
Contributor

@hrithikesh026 hrithikesh026 commented Oct 22, 2024

Type of Change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring
  • Dependency updates
  • Documentation
  • CI/CD

Description

Changes in this PR.

  • Changed the types of following fields in PaymentIntent Diesel and Domain models to appropriate Structs from serde::Value
  • Renamed struct AuthenticationDataV2 to AuthenticationData and added v1 and v2feature flags

Additional Changes

  • This PR modifies the API contract
  • This PR modifies the database schema
  • This PR modifies application configuration/environment variables

Motivation and Context

How did you test it?

Checklist

  • I formatted the code cargo +nightly fmt --all
  • I addressed lints thrown by cargo clippy
  • I reviewed the submitted code
  • I added unit tests for my changes where possible

@hrithikesh026 hrithikesh026 self-assigned this Oct 22, 2024
@hrithikesh026 hrithikesh026 requested review from a team as code owners October 22, 2024 11:07
Copy link

semanticdiff-com bot commented Oct 22, 2024

Review changes with SemanticDiff.

Analyzed 44 of 46 files.

Overall, the semantic diff is 5% smaller than the GitHub diff.

File Information
Filename Status
Cargo.lock Unsupported file format
✔️ crates/router/tests/connectors/payme.rs Analyzed
✔️ crates/router/tests/connectors/zen.rs Analyzed
✔️ crates/router/src/analytics.rs Analyzed
✔️ crates/router/src/services/authentication.rs Analyzed
✔️ crates/router/src/routes/admin.rs Analyzed
✔️ crates/router/src/routes/app.rs Analyzed
✔️ crates/router/src/routes/cards_info.rs Analyzed
✔️ crates/router/src/routes/currency.rs Analyzed
✔️ crates/router/src/routes/disputes.rs Analyzed
✔️ crates/router/src/routes/files.rs Analyzed
✔️ crates/router/src/routes/payment_methods.rs Analyzed
✔️ crates/router/src/routes/payments.rs Analyzed
✔️ crates/router/src/routes/payout_link.rs Analyzed
✔️ crates/router/src/routes/payouts.rs Analyzed
✔️ crates/router/src/routes/profiles.rs Analyzed
✔️ crates/router/src/routes/routing.rs Analyzed
✔️ crates/router/src/routes/verification.rs Analyzed
✔️ crates/router/src/routes/verify_connector.rs Analyzed
✔️ crates/router/src/db/kafka_store.rs 63.23% smaller
✔️ crates/router/src/db/merchant_account.rs 70.78% smaller
✔️ crates/router/src/core/utils.rs 0.29% smaller
✔️ crates/router/src/core/payments/transformers.rs 59.62% smaller
✔️ crates/router/src/core/fraud_check/types.rs 70.34% smaller
✔️ crates/router/src/connector/utils.rs 23.14% smaller
✔️ crates/router/src/connector/signifyd/transformers/api.rs Analyzed
✔️ crates/router/src/connector/riskified/transformers/api.rs Analyzed
✔️ crates/router/src/connector/adyen/transformers.rs 77.62% smaller
✔️ crates/openapi/src/openapi.rs Analyzed
✔️ crates/openapi/src/openapi_v2.rs 19.75% smaller
✔️ crates/masking/src/strategy.rs Analyzed
✔️ crates/hyperswitch_domain_models/src/lib.rs Analyzed
✔️ crates/hyperswitch_domain_models/src/payments.rs 34.25% smaller
✔️ crates/hyperswitch_domain_models/src/router_request_types.rs Analyzed
✔️ crates/hyperswitch_domain_models/src/types.rs Analyzed
✔️ crates/hyperswitch_domain_models/src/router_request_types/fraud_check.rs Analyzed
✔️ crates/hyperswitch_domain_models/src/payments/payment_intent.rs 43.18% smaller
✔️ crates/hyperswitch_connectors/src/utils.rs 0.83% smaller
✔️ crates/diesel_models/src/lib.rs Analyzed
✔️ crates/diesel_models/src/payment_intent.rs 2.6% smaller
✔️ crates/diesel_models/src/types.rs Analyzed
✔️ crates/common_utils/src/hashing.rs 9.09% smaller
crates/common_enums/Cargo.toml Unsupported file format
✔️ crates/common_enums/src/enums.rs Analyzed
✔️ crates/common_enums/src/enums/payments.rs Analyzed
✔️ crates/api_models/src/payments.rs 0.18% smaller

@hrithikesh026 hrithikesh026 added S-waiting-on-review Status: This PR has been implemented and needs to be reviewed C-refactor Category: Refactor labels Oct 23, 2024
@hrithikesh026 hrithikesh026 changed the title chore: change serde value to strict type in domain and diesel model chore: change serde value to strict type in payment intent domain and diesel model Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-refactor Category: Refactor S-waiting-on-review Status: This PR has been implemented and needs to be reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants