Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
drahnr committed Apr 9, 2024
1 parent 2f63cc2 commit 41a421b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
3 changes: 2 additions & 1 deletion progenitor-impl/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,8 @@ impl Generator {
// are currently...
OperationParameterType::RawBody => None,

OperationParameterType::Type(body_type_id) => {
OperationParameterType::Type(body_type_id)
| OperationParameterType::Form(body_type_id) => {
Some(body_type_id)
}
});
Expand Down
7 changes: 4 additions & 3 deletions progenitor-impl/src/httpmock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,8 @@ impl Generator {
name, typ, kind, ..
}| {
let arg_type_name = match typ {
OperationParameterType::Type(arg_type_id) => self
OperationParameterType::Type(arg_type_id)
| OperationParameterType::Form(arg_type_id) => self
.type_space
.get_type(arg_type_id)
.unwrap()
Expand Down Expand Up @@ -245,9 +246,9 @@ impl Generator {
OperationParameterKind::Header(_) => quote! { todo!() },
OperationParameterKind::Body(body_content_type) => {
match typ {
OperationParameterType::Type(_) => quote! {
OperationParameterType::Type(_)
| OperationParameterType::Form(_) => quote! {
Self(self.0.json_body_obj(value))

},
OperationParameterType::RawBody => {
match body_content_type {
Expand Down

0 comments on commit 41a421b

Please sign in to comment.