mirror of
https://github.com/classilla/tenfourfox.git
synced 2024-09-10 11:54:40 +00:00
16 lines
417 B
JavaScript
16 lines
417 B
JavaScript
addEventListener("error", function(e) {
|
|
var obj = {};
|
|
for (var prop of ["message", "filename", "lineno"]) {
|
|
obj[prop] = e[prop]
|
|
}
|
|
obj.type = "event";
|
|
postMessage(obj);
|
|
});
|
|
onerror = function(message, filename, lineno) {
|
|
var obj = { message: message, filename: filename, lineno: lineno,
|
|
type: "callback" }
|
|
postMessage(obj);
|
|
return false;
|
|
}
|
|
throw new Error("workerhello");
|