Conversation
|
Can you pass in the new params directly instead? The current change may be a bit misleading, and we can pass in default params for |
jtliao
left a comment
There was a problem hiding this comment.
have msgId and threadId as parameters with default values
|
Having Wit.message() to receive more params it's not maintainable. It just increases the Cyclomatic complexity. A good approach to solve this problem is to have an object with the params we want. See issue #189. |
|
I would argue the complexity is higher if a single argument takes different forms. I'm not sure how adding two params with default values makes thing not maintainable. |
|
if we pass a single object we can just iterate over the properties of such object instead of adding more Regarding the maintainability, what will happen if suddenly the |
|
Updated the PR to show what the implementation look like |
Fixes issue #189, #191 & #169.