Add test case for undefined method args
It Vue it is possible to define methods which directly calls another method.
Examples
methods: {
someMethod: MethodThatReturnAFunction(),
}
OR
methods: {
someMethod: CallsSomeOtherMethod,
}
Explanation
In that case the method would have parameters, so hasParams
would pass, but method.args
would be undefined
.
I added a check which simply sets args
to a blank string ""
if method.args
is null.
Use Case
methods: {
calledVeryOften: functionsThatReturnsADebouncedFunction(),
}
Edited by Lourens