[java-shib-shared] branch main updated: Code cleanup.

Scott Cantor cantor.2 at osu.edu
Tue May 14 20:19:47 UTC 2024


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch main
in repository java-shib-shared.

View the commit online:
http://git.shibboleth.net/view/?p=java-shib-shared.git;a=commit;h=ba38d686a148bebc10b86beda6dbd4596e87132a

The following commit(s) were added to refs/heads/main by this push:
     new ba38d686 Code cleanup.
ba38d686 is described below

commit ba38d686a148bebc10b86beda6dbd4596e87132a
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Tue May 14 16:19:45 2024 -0400

    Code cleanup.
---
 .../shared/spring/service/impl/SpringServiceableComponent.java       | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/shib-service/src/main/java/net/shibboleth/shared/spring/service/impl/SpringServiceableComponent.java b/shib-service/src/main/java/net/shibboleth/shared/spring/service/impl/SpringServiceableComponent.java
index 839e9911..ea8f687b 100644
--- a/shib-service/src/main/java/net/shibboleth/shared/spring/service/impl/SpringServiceableComponent.java
+++ b/shib-service/src/main/java/net/shibboleth/shared/spring/service/impl/SpringServiceableComponent.java
@@ -15,7 +15,6 @@
 package net.shibboleth.shared.spring.service.impl;
 
 import javax.annotation.Nonnull;
-import javax.annotation.Nullable;
 
 import net.shibboleth.shared.component.IdentifiableComponent;
 import net.shibboleth.shared.service.ServiceableComponent;
@@ -39,8 +38,8 @@ public class SpringServiceableComponent<T> extends AbstractServiceableComponent<
      */
     public SpringServiceableComponent(@Nonnull final T what) {
         theComponent = what;
-        if (what instanceof IdentifiableComponent) {
-            @Nullable final String id = ((IdentifiableComponent) what).getId();
+        if (what instanceof IdentifiableComponent c) {
+            final String id = c.getId();
             if (id != null) {
                 setId(id);
             }

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list