Skip to content

fix: snakecase conversion for strings with numbers - #8111

Merged
imnotjames merged 1 commit into
typeorm:masterfrom
julius-welink:fix-snake-case-conversion
Aug 25, 2021
Merged

imnotjames merged 1 commit into
typeorm:masterfrom
julius-welink:fix-snake-case-conversion

Conversation

@julius-welink

@julius-welink julius-welink commented Aug 24, 2021 •

Copy link
Copy Markdown
Contributor

Fix a specific case of converting device1Status -> device1_status

Description of change

the change in eb680f9 has broke one case of how cammelCase is converted to snake_case, specifically:
device1Status -> device1status

this PR restores the correct behavior:
device1Status -> device1_status

Pull-Request Checklist

  • Code is up-to-date with the master branch
  • npm run lint passes with this change
  • npm run test passes with this change
  • This pull request links relevant issues as Fixes #0000 (relevant issue not found)
  • There are new or updated unit tests validating the change
  • Documentation has been updated to reflect this change (no change required)
  • The new commits follow conventions explained in CONTRIBUTING.md

Fix a specific case of converting device1Status -> device1_status
@julius-welink

Copy link
Copy Markdown
Contributor Author

@imnotjames

@julius-welink

julius-welink commented Aug 24, 2021 •

Copy link
Copy Markdown
Contributor Author

image

haven't touched those ¯\_(ツ)_/¯ Please re-run tests.

@imnotjames

Copy link
Copy Markdown
Contributor

Awesome catch!

I'll re-run the tests as well.

@imnotjames
imnotjames merged commit 749511d into typeorm:master Aug 25, 2021
@imnotjames

Copy link
Copy Markdown
Contributor

Thanks for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants