0.1.4 correct url encoding of query parameters
This commit is contained in:
@@ -116,14 +116,14 @@ impl ListAccountsOptions {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[accountType]={}", value));
|
||||
query.push_str(&format!("filter[accountType]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if let Some(value) = &self.filter_ownership_type {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[ownershipType]={}", value));
|
||||
query.push_str(&format!("filter[ownershipType]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if !query.is_empty() {
|
||||
|
@@ -108,7 +108,7 @@ impl ListCategoriesOptions {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[parent]={}", value));
|
||||
query.push_str(&format!("filter[parent]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if !query.is_empty() {
|
||||
|
@@ -251,35 +251,35 @@ impl ListTransactionsOptions {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[status]={}", value));
|
||||
query.push_str(&format!("filter[status]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if let Some(value) = &self.filter_since {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[since]={}", value));
|
||||
query.push_str(&format!("filter[since]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if let Some(value) = &self.filter_until {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[until]={}", value));
|
||||
query.push_str(&format!("filter[until]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if let Some(value) = &self.filter_category {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[category]={}", value));
|
||||
query.push_str(&format!("filter[category]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if let Some(value) = &self.filter_tag {
|
||||
if !query.is_empty() {
|
||||
query.push('&');
|
||||
}
|
||||
query.push_str(&format!("filter[tag]={}", value));
|
||||
query.push_str(&format!("filter[tag]={}", urlencoding::encode(value)));
|
||||
}
|
||||
|
||||
if !query.is_empty() {
|
||||
|
Reference in New Issue
Block a user