Additional check needed before using the `in` operator for CustomEvent.detail
jsvini opened this issue · comments
Vinícius Alves commented
Describe the bug
Hi, the mask crashes when CustomEvent.detail is a number, the if
bellow assumes that CustomEvent.detail is always null or an object, but since it's a CustomEvent, it can have anything in the detail
property.
Line 93 in b8a2fe8
Need to check if CustomEvent.detail is an object|array before using the in
operator, or it will crash when it's something else.
Steps to reproduce
Try to fill this input, it will crash the mask:
Alexander Shabunevich commented
Thanks, fixed in v2.1.3