mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-11-09 12:51:09 +02:00
MozReview-Commit-ID: LABOJnYtpD5 --HG-- extra : rebase_source : 86c27b8a2deb388cdb34a82aebd12b042477acb5
10 lines
273 B
JavaScript
10 lines
273 B
JavaScript
this.onpush = function(event) {
|
|
var request = event.data.json();
|
|
if (request.type == "exception") {
|
|
throw new Error("Uncaught exception");
|
|
}
|
|
if (request.type == "rejection") {
|
|
event.waitUntil(Promise.reject(
|
|
new Error("Unhandled rejection")));
|
|
}
|
|
};
|