use JenkinsLocationConfiguration.get()#9
use JenkinsLocationConfiguration.get()#9jovandeginste merged 1 commit intojenkinsci:masterfrom dodgex:fix_notification_url
Conversation
|
@dodgex thanks for the PR - I will be running your PR in my setup for a few days |
|
Nicely done. I'll probably use it as well, unless it gets merged upstream pretty soon. |
|
@furai Feel free to run it! I will try to merge and publish on Monday |
|
@dodgex While building the release, firebug complained about this: Would you mind adding a |
|
I have added a new commit. |
|
@dodgex I added two comments as review |
| JenkinsLocationConfiguration jenkinsConfig = JenkinsLocationConfiguration.get(); | ||
| return jenkinsConfig.getUrl(); | ||
| String url = jenkinsConfig.getUrl(); | ||
| if (url == null) { |
There was a problem hiding this comment.
@dodgex I think the test should be whether jenkinsConfig is null (and thus one line higher)
There was a problem hiding this comment.
return (jenkinsConfig == null) ? null : jenkinsConfig.getUrl();
/ from the peanut gallery :)
There was a problem hiding this comment.
sorry for the false check, i have checked the docs and it didnt seem that get() would return null and for getUrl() it has @CheckForNull...
| JenkinsLocationConfiguration jenkinsConfig = JenkinsLocationConfiguration.get(); | ||
| return jenkinsConfig.getUrl(); | ||
| String url = jenkinsConfig.getUrl(); | ||
| if (url == null) { |
There was a problem hiding this comment.
@dodgex same as my other comment
|
FYI, you can test this by running |
instead of new JenkinsLocationConfiguration() Trying to fix: https://issues.jenkins-ci.org/browse/JENKINS-54054 Inspired by: jenkinsci/stash-pullrequest-builder-plugin#26
|
PR is updated and changes have been squashed |
|
running the new version in our set-up now |
|
New release is coming your way! |
|
Thank you for merging ! :) |
instead of new JenkinsLocationConfiguration()
Trying to fix: https://issues.jenkins-ci.org/browse/JENKINS-54054
Inspired by: jenkinsci/stash-pullrequest-builder-plugin#26