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

Weird naming behaviour #136

Open
phadaphunk opened this issue Nov 26, 2020 · 2 comments
Open

Weird naming behaviour #136

phadaphunk opened this issue Nov 26, 2020 · 2 comments
Labels
bug Something isn't working Double-Check Good Issue Nice catch v5 version 5, supports both API and self hosted

Comments

@phadaphunk
Copy link
Contributor

Describe the bug
The naming behaviour is weird. It will lowercase your whole name and add Mail at the end. It does not respect the PascalCase if multiple words are in the name. Also, if you have the word email at the end of the name it won't add the word Mail but will lowercase the word email which makes it inconsistent with the rest.

To Reproduce
Steps to reproduce the behavior:
Create a new Mailable via the UI with the following names.


  • Input : ConfirmationEmail
  • Expected : ConfirmationEmail (or ConfirmationEmailMail to fit your standard)
  • Result : Confirmationemail

  • Input : PasswordConfirmation
  • Expected : PasswordConfirmationMail
  • Result : PasswordconfirmationMail

Another weird thing is the UI specifically gives this as example : WelcomeUser which is weird because it will be named WelcomeuserMail instead of the real input that was WelcomeUser. It can be renamed in the project and still work properly but it feels more like a bug to me.

Laravel Application: Laravel 8
Maileclipse package version: 3.2

@phadaphunk phadaphunk added the bug Something isn't working label Nov 26, 2020
@phadaphunk
Copy link
Contributor Author

I read your tests and it seems to be... by design?

'CustomerMail' => 'Customermail',
'Customermail' => 'Customermail',
'Customer Mail' => 'CustomerMail',
'customer mail' => 'CustomerMail',

Hmm.

@ReeceM ReeceM added the Good Issue Nice catch label Nov 26, 2020
@ReeceM
Copy link
Collaborator

ReeceM commented Nov 26, 2020

I read your tests and it seems to be... by design?

'CustomerMail' => 'Customermail',
'Customermail' => 'Customermail',
'Customer Mail' => 'CustomerMail',
'customer mail' => 'CustomerMail',

Hmm.

Hi @phadaphunk with regards the tests, those were done but the contributor to match the initial design by the of the package. So that can be adjusted anyways. At least we know that it gives the correct wrong result 🤣.

But yes, the naming convention is a little non-standard currently. Thank you for raising the issue on the repo.

I will see if this can be either PR'd or worked into the refactoring of the codebase. But I paused that a little as I opted to sort out the unit tests as a whole to ensure that none of the refactoring messed things up.

@ReeceM ReeceM added this to the Refactoring Package milestone Nov 26, 2020
@ReeceM ReeceM added the WIP Work in progress label Dec 10, 2020
@ReeceM ReeceM added this to High priority in Bug Tracking Jun 25, 2021
@Qoraiche Qoraiche added Double-Check v5 version 5, supports both API and self hosted and removed WIP Work in progress labels Aug 2, 2023
@Qoraiche Qoraiche moved this from High priority to Needs triage in Bug Tracking Aug 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Double-Check Good Issue Nice catch v5 version 5, supports both API and self hosted
Projects
Bug Tracking
  
Needs triage
Development

No branches or pull requests

3 participants