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

fix NPE on MethodFormat.getCodeSource suggest by @brasmusson #757

Merged
merged 1 commit into from Aug 5, 2014
Merged

fix NPE on MethodFormat.getCodeSource suggest by @brasmusson #757

merged 1 commit into from Aug 5, 2014

Conversation

bySabi
Copy link

@bySabi bySabi commented Aug 4, 2014

This fix same issue of PR: #751

@brasmusson suggest this approach and here is code.

@brasmusson brasmusson merged commit 3010af6 into cucumber:master Aug 5, 2014
brasmusson added a commit that referenced this pull request Aug 5, 2014
Also fix indentation of MethodFormat.getCodeSource.
@brasmusson
Copy link
Contributor

The comments on #751 was positive, so I decided I could merge this PR.
Thank you for tracking down these NullPointerExceptions, @bySabi

// getProtectionDomain() returns null on some platforms (for example on Android)
return method.getDeclaringClass().getName();
try {
ProtectionDomain protectionDomain = method.getDeclaringClass().getProtectionDomain();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This does not conform to the 4 space indent specified in Contributing.md, (and neither did the example code I wrote in the comment in PR-751).
I fixed the indenting when I merged the PR.

@lock
Copy link

lock bot commented Oct 25, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Oct 25, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants