Closed elboletaire closed 8 years ago
I'm currently fixing the constant issue. At first I thought it was due to the array shortcuts but later I've seen it's due to the usage of the constant as an array, which is not supported until php 5.6.
I forgot that there's an interface which specifies how the personId
method should be. So, I've removed the optional param and now personId
checks for any valid NIF type.
No comments about this @dereuromark @antograssiot ??
Looks good apart from my comments about more strictness.
Thanks for the revision @dereuromark. I'll do the fixes when I can.
Changes done :smile:
As said in #117 we have more than one personId type. For that reason I've created three methods (a part from the
personId
itself):dni
. These are the common personIds.nif
. These begin withK
,L
orM
.nie
. These begin withX
,Y
orZ
.For this reason, I've implemented
personId
to check all them by default, but you can specify which types you wanna check with its second parameter: