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 NullPointerException in ResponseDefinition.getProxyUrl() #2490

Merged
merged 2 commits into from
Nov 28, 2023
Merged

Fix NullPointerException in ResponseDefinition.getProxyUrl() #2490

merged 2 commits into from
Nov 28, 2023

Conversation

mfruizs
Copy link
Contributor

@mfruizs mfruizs commented Nov 15, 2023

Added safe programming when we instantiate ResponseDefinition class and use getProxyUrl() method when originalRequest field is set to null

References

Submitter checklist

  • Recommended: Join WireMock Slack to get any help in #help-contributing or a project-specific channel like #wiremock-java
  • Recommended: If you participate in Hacktoberfest 2023, make sure you're signed up there and in the WireMock form
  • The PR request is well described and justified, including the body and the references
  • The PR title represents the desired changelog entry
  • The repository's code style is followed (see the contributing guide)
  • Test coverage that demonstrates that the change works as expected
  • For new features, there's necessary documentation in this pull request or in a subsequent PR to wiremock.org

@mfruizs mfruizs requested a review from a team as a code owner November 15, 2023 15:05
Copy link
Member

@oleg-nenashev oleg-nenashev left a comment

Choose a reason for hiding this comment

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

LGTM. We should enforce static analysis in WireMock APIs, because it will be difficult to maintain the extension eco system otherwise

@oleg-nenashev oleg-nenashev changed the title [Issue-2489] fix NullPointerException on ResponseDefinition.getProxyUrl Fix NullPointerException in ResponseDefinition.getProxyUrl() Nov 21, 2023
@oleg-nenashev oleg-nenashev merged commit 8ce872e into wiremock:master Nov 28, 2023
7 checks passed
@mfruizs mfruizs deleted the issue-2489-fix-get-proxy-url-npe branch December 6, 2023 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants