mirror of
				https://github.com/juspay/hyperswitch.git
				synced 2025-10-31 18:17:13 +08:00 
			
		
		
		
	refactor: Rename business profile to profiles in api, diesel, domain, interface and error types (#5877)
Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
This commit is contained in:
		| @ -182,11 +182,11 @@ pub async fn update_merchant_active_algorithm_ref( | ||||
| } | ||||
|  | ||||
| #[cfg(feature = "v1")] | ||||
| pub async fn update_business_profile_active_algorithm_ref( | ||||
| pub async fn update_profile_active_algorithm_ref( | ||||
|     db: &dyn StorageInterface, | ||||
|     key_manager_state: &KeyManagerState, | ||||
|     merchant_key_store: &domain::MerchantKeyStore, | ||||
|     current_business_profile: domain::BusinessProfile, | ||||
|     current_business_profile: domain::Profile, | ||||
|     algorithm_id: routing_types::RoutingAlgorithmRef, | ||||
|     transaction_type: &storage::enums::TransactionType, | ||||
| ) -> RouterResult<()> { | ||||
| @ -214,12 +214,12 @@ pub async fn update_business_profile_active_algorithm_ref( | ||||
|         storage::enums::TransactionType::Payout => (None, Some(ref_val)), | ||||
|     }; | ||||
|  | ||||
|     let business_profile_update = domain::BusinessProfileUpdate::RoutingAlgorithmUpdate { | ||||
|     let business_profile_update = domain::ProfileUpdate::RoutingAlgorithmUpdate { | ||||
|         routing_algorithm, | ||||
|         payout_routing_algorithm, | ||||
|     }; | ||||
|  | ||||
|     db.update_business_profile_by_profile_id( | ||||
|     db.update_profile_by_profile_id( | ||||
|         key_manager_state, | ||||
|         merchant_key_store, | ||||
|         current_business_profile, | ||||
| @ -241,17 +241,17 @@ pub async fn update_business_profile_active_dynamic_algorithm_ref( | ||||
|     db: &dyn StorageInterface, | ||||
|     key_manager_state: &KeyManagerState, | ||||
|     merchant_key_store: &domain::MerchantKeyStore, | ||||
|     current_business_profile: domain::BusinessProfile, | ||||
|     current_business_profile: domain::Profile, | ||||
|     dynamic_routing_algorithm: routing_types::DynamicRoutingAlgorithmRef, | ||||
| ) -> RouterResult<()> { | ||||
|     let ref_val = dynamic_routing_algorithm | ||||
|         .encode_to_value() | ||||
|         .change_context(errors::ApiErrorResponse::InternalServerError) | ||||
|         .attach_printable("Failed to convert dynamic routing ref to value")?; | ||||
|     let business_profile_update = domain::BusinessProfileUpdate::DynamicRoutingAlgorithmUpdate { | ||||
|     let business_profile_update = domain::ProfileUpdate::DynamicRoutingAlgorithmUpdate { | ||||
|         dynamic_routing_algorithm: Some(ref_val), | ||||
|     }; | ||||
|     db.update_business_profile_by_profile_id( | ||||
|     db.update_profile_by_profile_id( | ||||
|         key_manager_state, | ||||
|         merchant_key_store, | ||||
|         current_business_profile, | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Arun Raj M
					Arun Raj M