Use `Array.isArray` instead of `instanceof`.  There are a few places in the code base that do this, so I would just do a global search.