firebase-element
firebase-element copied to clipboard
Firing an event when a set or update fails
trafficstars
Hello,
I would like to listen to 'set' or 'update' failures (e.g. because of a rule not matching, etc).
I wrote a quick fix for myself in Typescript:
this.query.child(key).set(value, (error) => {
this._log(error);
this.fire('firebase-set-error', error);
});
However I think it'd better be implemented following your coding style, but I'm not really fluent in Javascript... And you probably have a pattern in mind...
Please let me know your thoughts. Eric.
+1
:+1: