I think the issue with my specific example is forcing the datatype there (obviously Response is not defined as a null, so there’s some typecasting that has to be done – it seems this is bad to do).
The thing I’m wondering right now is this:
Let us say that we let the user pass us a “list of any data type”. How do we tell if that list is (1) a list of complex objects with fields or (2) a list of primitives. I literally, actually cannot figure it out.
Surely one of the more experienced plugin wranglers here knows the correct/fastest/most performant way to tell this.
(I can’t come up with a single boolean expression that will evaluate false for one and true for the other… but I suck at some JavaScript stuff. Every time I think “ah, I have the solution!” the expression throws an error. So I just keep thrashing on this and thrashing is bad…)