Skip to content

Commit

Permalink
Merge pull request #209 from jenkinsci/dependabot/maven/org.jenkins-c…
Browse files Browse the repository at this point in the history
…i.plugins-plugin-4.77

build(deps): bump org.jenkins-ci.plugins:plugin from 4.76 to 4.77
  • Loading branch information
jimklimov authored Jan 22, 2024
2 parents 82b9ec6 + e804dfd commit b93c351
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>plugin</artifactId>
<version>4.76</version>
<version>4.77</version>
<relativePath />
</parent>

Expand Down
7 changes: 7 additions & 0 deletions src/main/java/hudson/plugins/im/IMConnectionProvider.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package hudson.plugins.im;

import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import hudson.model.User;
import hudson.plugins.im.tools.ExceptionHelper;
import java.util.concurrent.Semaphore;
Expand Down Expand Up @@ -125,6 +126,12 @@ public Authentication getAuthentication() {
return authentication;
}

// New spotbugs UWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTOR
// just can't be quiesced, so duplicating the sanity-check here
if (descriptor == null || descriptor.getHudsonUserName() == null) {
return null;

Check warning on line 132 in src/main/java/hudson/plugins/im/IMConnectionProvider.java

View check run for this annotation

ci.jenkins.io / Code Coverage

Not covered lines

Lines 131-132 are not covered by tests
}

User u = User.get(descriptor.getHudsonUserName());

return u.impersonate();
Expand Down

0 comments on commit b93c351

Please sign in to comment.