Skip to content

static access to normalizeMediaType in typescript object serializer#20202

Merged
macjohnny merged 1 commit into
OpenAPITools:masterfrom
bbortt:fix/#20201-typescript-object-serializer
Nov 28, 2024
Merged

static access to normalizeMediaType in typescript object serializer#20202
macjohnny merged 1 commit into
OpenAPITools:masterfrom
bbortt:fix/#20201-typescript-object-serializer

Conversation

@bbortt

@bbortt bbortt commented Nov 28, 2024

Copy link
Copy Markdown
Contributor

accessing normalizeMediaType should be done static in ObjectSerializer, as described in #20201.

fix applies only to the typescript generator.

closes #20201 if accepted as solution by maintainers.

PR checklist

  • Read the contribution guidelines.
  • Pull Request title clearly describes the work in the pull request and Pull Request description provides details about how to validate the work. Missing information here may result in delayed response from the community.
  • Run the following to build the project and update samples:
    ./mvnw clean package || exit
    ./bin/generate-samples.sh ./bin/configs/*.yaml || exit
    ./bin/utils/export_docs_generators.sh || exit
    
    (For Windows users, please run the script in Git BASH)
    Commit all changed files.
    This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master.
    These must match the expectations made by your contribution.
    You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example ./bin/generate-samples.sh bin/configs/java*.
    IMPORTANT: Do NOT purge/delete any folders/files (e.g. tests) when regenerating the samples as manually written tests may be removed.
  • File the PR against the correct branch: master (upcoming 7.x.0 minor release - breaking changes with fallbacks), 8.0.x (breaking changes without fallbacks)
  • If your PR is targeting a particular programming language, @mention the technical committee members, so they are more likely to review the pull request.

cc: @joscha

…cript object serializer

accessing `normalizeMediaType` should be done static in `ObjectSerializer`, as described
in OpenAPITools#20201.

fix applies only to the `typescript` generator.

@joscha joscha left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ObjectSerializer is in the * import, yes? I haven't actually checked. Intent LGTM

@joscha

joscha commented Nov 28, 2024

Copy link
Copy Markdown
Contributor

@macjohnny @wing328 I'll need one of you for approving workflows and then merging this, please.

@macjohnny macjohnny merged commit 326f100 into OpenAPITools:master Nov 28, 2024
@joscha

joscha commented Nov 28, 2024

Copy link
Copy Markdown
Contributor

@macjohnny did you check ObjectSerializer is in there? I wasn't actually sure and was hoping for the CI to tell us 👯

@macjohnny

Copy link
Copy Markdown
Member

@macjohnny did you check ObjectSerializer is in there? I wasn't actually sure and was hoping for the CI to tell us 👯

it is in the very same file, its the class that is defined in that file

@joscha

joscha commented Nov 28, 2024

Copy link
Copy Markdown
Contributor

it is in the very same file, its the class that is defined in that file

I looked and must have scrolled past it :-/ Thank you!

@bbortt bbortt deleted the fix/#20201-typescript-object-serializer branch November 28, 2024 13:49
@bbortt

bbortt commented Nov 28, 2024

Copy link
Copy Markdown
Contributor Author

it is in the very same file, its the class that is defined in that file

sorry for my late answer, I was out of office for lunch. that is correct. the method is a static method of this very class.

thanks for your quick doing guys!

@wing328 wing328 added this to the 7.11.0 milestone Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG][typescript] Cannot read properties of undefined (reading 'normalizeMediaType')

4 participants