Skip to content

Commit

Permalink
fix: rename redirect_url to return_url on ConfirmSetupIntent
Browse files Browse the repository at this point in the history
### Description
As raised on arlyon#504, this attribute have the incorrect
name according to the [documentation](https://docs.stripe.com/api/setup_intents/confirm#confirm_setup_intent-return_url).

This change renames the field `redirect_url` to `return_url`.

closes arlyon#504
  • Loading branch information
augustoccesar committed Feb 26, 2024
1 parent 19f4551 commit 9da5a28
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions src/resources/setup_intent_ext.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ use crate::client::{Client, Response};
use crate::resources::SetupIntent;
use crate::{SetupIntentCancellationReason, SetupIntentId};

/// The set of parameters that can be used when confirming a setup_intent object.
///
/// For more details see <https://stripe.com/docs/api/setup_intents/confirm>
#[derive(Clone, Debug, Serialize)]
pub struct ConfirmSetupIntent {
/// The client secret if on the client side
Expand All @@ -14,11 +17,11 @@ pub struct ConfirmSetupIntent {
#[serde(skip_serializing_if = "Option::is_none")]
pub payment_method: Option<String>,

//Mandate data and payment method options not implemented. If you want
//something better, create an issue and lets fix
/// Where to redirect the user after they log out of their dashboard.
// Mandate data and payment method options not implemented. If you want
// something better, create an issue and lets fix
/// The URL to redirect your customer back to after they authenticate on the payment method’s app or site.
#[serde(skip_serializing_if = "Option::is_none")]
pub redirect_url: Option<String>,
pub return_url: Option<String>,
}

/// The set of parameters that can be used when canceling a setup_intent object.
Expand Down

0 comments on commit 9da5a28

Please sign in to comment.