Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not cause an error when trying to stringify a NativeError. #201

Closed
gbrail opened this issue Jun 17, 2015 · 0 comments
Closed

Do not cause an error when trying to stringify a NativeError. #201

gbrail opened this issue Jun 17, 2015 · 0 comments
Milestone

Comments

@gbrail
Copy link
Collaborator

gbrail commented Jun 17, 2015

This is currently the bug:

$ rhino
Rhino 1.7.6 2015 04 15
js> try { somethingundefined(); } catch (e) { JSON.stringify(e); }
js: Java class "[B" has no public instance field or method named "toJSON".

With the fix, the proper behavior is this:

Rhino 1.7.7 2015 06 17
js> try { somethingundefined(); } catch (e) { JSON.stringify(e); }
{"message":""somethingundefined" is not defined.","fileName":"","lineNumber":2}

@gbrail gbrail added this to the Release 1.7.7 milestone Jun 17, 2015
@gbrail gbrail closed this as completed Jun 17, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant