I am working on a custom widget. One of the things I need to do is to query a group item from AGOL. To do this I use the query items methods as below with the required parameters.
When I work authenticated with an enterprise login, it all worked as it was expected. But when I authenticated with an AGOL user I receive an error: Uncaught RangeError: Maximum call stack size exceeded. It was that when the request that is shown above was done, ArcGIS javascript API was generating an object with a circular reference and the widget crashes. The request is a search (