use `Array.isArray` for all such checks