Skip to content

Commit

Permalink
refactor: comment on empty constructor, avoid local variable before r…
Browse files Browse the repository at this point in the history
…eturning
  • Loading branch information
lrosenfeldt committed Aug 7, 2024
1 parent 810e35b commit 8671e8c
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,12 @@
})
public class ServerMetaInfo implements Serializable {
public static ServerMetaInfo withDefaults(String integrator) {
ServerMetaInfo serverMetaInfo = new ServerMetaInfo()
return new ServerMetaInfo()
.platformIdentifier(String.format("%s, java version is: %s", System.getProperty("os.name"),
System.getProperty("java.version")))
.sdkIdentifier("JavaServerSDK/v0.0.2")
.sdkCreator("PAYONE GmbH")
.integrator(integrator);
return serverMetaInfo;
}

public static ServerMetaInfo withDefaults() {
Expand All @@ -41,6 +40,8 @@ public static ServerMetaInfo withDefaults() {
private String integrator;

public ServerMetaInfo() {
// empty constructor
// required for Jackson deserialization
}

public ServerMetaInfo platformIdentifier(String platformIdentifier) {
Expand Down

0 comments on commit 8671e8c

Please sign in to comment.