Skip to content

Commit

Permalink
fixed non concrete return type
Browse files Browse the repository at this point in the history
  • Loading branch information
supertick committed Oct 25, 2023
1 parent 0dfa3d0 commit 3b12214
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/main/java/org/myrobotlab/framework/Service.java
Original file line number Diff line number Diff line change
Expand Up @@ -1408,9 +1408,8 @@ public T getConfig() {
return config;
}

public <P extends ServiceConfig> P getPeerConfig(String peerKey) {
return getPeerConfig(peerKey, new StaticType<>() {
});
public ServiceConfig getPeerConfig(String peerKey) {
return getPeerConfig(peerKey, new StaticType<ServiceConfig>() {});
}


Expand Down Expand Up @@ -1457,7 +1456,7 @@ public <P extends ServiceConfig> P getPeerConfig(String peerKey, StaticType<P> t
}

public void setPeerConfigValue(String peerKey, String fieldname, Object value) throws NoSuchFieldException, SecurityException, IllegalArgumentException, IllegalAccessException {
ServiceConfig sc = getPeerConfig(peerKey, new StaticType<>() {});
ServiceConfig sc = getPeerConfig(peerKey, new StaticType<ServiceConfig>() {});
if (sc == null) {
error("invalid config for peer key %s field name %s", peerKey, fieldname);
return;
Expand Down

0 comments on commit 3b12214

Please sign in to comment.