You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In our internal projects I see default value for the method's parameters used frequently, and I think that it can be a toxic for a best understanding, because normally it's means Business Rules but hidden.
Hello Folks,
In our internal projects I see default value for the method's parameters used frequently, and I think that it can be a toxic for a best understanding, because normally it's means Business Rules but hidden.
For example:
And we can call it using:
Ok, it's will run gracefully...
But the next Developer need to read the model's code to understand that
overdue
need to receive a date parameter, and if this date isn't .In our method's guide (https://github.com/internetsistemas/guides/tree/master/style-guides/ruby#methods) we encourage devs to use named parameters for best understanding.
What do you think?
The text was updated successfully, but these errors were encountered: