Sign In Register

How can we help you today?

Start a new topic
Answered

JS GlobalEventHandlers.onerror

In real time api is there a function that intercepts all the errors? By analogy with js:

"window.onerror = function (errorMsg, url, lineNumber) { ... }"


Best Answer

Hi Vsevolod,


The realtime.log collection in the NoSQL Tab should contain any global errors in a realtime script. You can also use RTLogger to log any debug messages you may need, I've provided a link to the documentation here: https://docs.gamesparks.com/api-documentation/realtime-api/rtlogger.html


I'd imagine you could write a function similar to your needs using RTLogger to actually log the data.


Hope this helps

 - Steve



1 Comment

Answer

Hi Vsevolod,


The realtime.log collection in the NoSQL Tab should contain any global errors in a realtime script. You can also use RTLogger to log any debug messages you may need, I've provided a link to the documentation here: https://docs.gamesparks.com/api-documentation/realtime-api/rtlogger.html


I'd imagine you could write a function similar to your needs using RTLogger to actually log the data.


Hope this helps

 - Steve



Login to post a comment