Fix error object wrapper (#914)
This commit is contained in:
parent
efd82ab5bd
commit
b11d1b2282
@ -83,8 +83,8 @@ var WorkerMessageHandler = {
|
|||||||
} catch (e) {
|
} catch (e) {
|
||||||
// Turn the error into an obj that can be serialized
|
// Turn the error into an obj that can be serialized
|
||||||
e = {
|
e = {
|
||||||
message: e.message,
|
message: typeof e === 'object' ? e.message : e,
|
||||||
stack: e.stack
|
stack: typeof e === 'object' ? e.stack : null
|
||||||
};
|
};
|
||||||
handler.send('page_error', {
|
handler.send('page_error', {
|
||||||
pageNum: pageNum,
|
pageNum: pageNum,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user