Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: Singular form of "invoices" is "invoice" #61

Closed
travisnewhouse opened this issue Nov 5, 2022 · 2 comments · Fixed by #62
Closed

bug: Singular form of "invoices" is "invoice" #61

travisnewhouse opened this issue Nov 5, 2022 · 2 comments · Fixed by #62
Labels
bug Something isn't working
Milestone

Comments

@travisnewhouse
Copy link

Description

Description

The singular form of "invoices" is "invoice". Similar words are "voices" -> "voice" and "choices" -> "choice". Flect.Singularize() does not return the correct singular form of these words. As a side note, flect.Pluralize() does return the proper plural form of the singular form of these words.

Expected Behavior

flect.Singularize("invoices") == "invoice"
flect.Singularize("voices") == "voice"
flect.Singularize("choices") == "choice"

Actual Behavior

flect.Singularize("invoices") == "invoex"
flect.Singularize("voices") == "voex"
flect.Singularize("choices") == "choex"

To Reproduce

No response

Additional Context

No response

@sio4 sio4 added the bug Something isn't working label Nov 5, 2022
@sio4 sio4 added this to the v0.3.1 milestone Nov 5, 2022
@sio4
Copy link
Member

sio4 commented Nov 5, 2022

Thanks for reporting this! Indeed, this is a bug and should be fixed as soon as possible.

I took a look at the code shortly and I think we need to fix the logic. We currently use a single table for both s-to-p and p-to-s, but they are not always reversible. I will check again soon.

@sio4
Copy link
Member

sio4 commented Dec 26, 2022

FYI, I am working on it with some other fundamental changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants