Closed SimonVillage closed 2 years ago
try {
subscription.publish(data);
} on Error catch (e) {
print(e);
}
You have to define on Error
then it will work. Would be better to have a different naming like CentrifugeError
. I will close this issue anyways.
My publish response is throwing an exception. I am trying to catch the exception but it doesn't work:
I return the error like this on my backend:
I wonder if it would be better to not return an error but something like a custom error to now have it convert into an exception? Something like