Skip to content

Commit

Permalink
Merge pull request #59 from starcoinorg/main_dagblock_fix_missing_hash
Browse files Browse the repository at this point in the history
[dag block] fixed the missing parents
  • Loading branch information
welbon authored Jun 21, 2024
2 parents ffb8627 + 5d9eec2 commit dbccbd3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>org.starcoin</groupId>
<artifactId>sdk</artifactId>
<version>1.2.2</version>
<version>1.2.3</version>

<name>Starcoin Java SDK</name>
<description>Starcoin Java SDK</description>
Expand Down
9 changes: 6 additions & 3 deletions src/main/java/org/starcoin/bean/BlockHeader.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,14 @@
import com.alibaba.fastjson.PropertyNamingStrategy;
import com.alibaba.fastjson.annotation.JSONField;
import com.alibaba.fastjson.annotation.JSONType;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.List;
import java.util.Vector;

@JSONType(naming = PropertyNamingStrategy.SnakeCase)
@JsonIgnoreProperties(ignoreUnknown = true)
public class BlockHeader extends Base {
long timestamp;

Expand Down Expand Up @@ -82,7 +85,7 @@ public class BlockHeader extends Base {

@JSONField(name = "parents_hash")
@JsonProperty("parents_hash")
private Vector<String> parentsHash;
private List<String> parentsHash;

public String getAuthor() {
return author;
Expand Down Expand Up @@ -212,11 +215,11 @@ public void setDifficultyHexStr(String difficultyHexStr) {
this.difficultyHexStr = difficultyHexStr;
}

public Vector<String> getParentsHash() {
public List<String> getParentsHash() {
return parentsHash;
}

public void setParentsHash(Vector<String> parentsHash) {
public void setParentsHash(List<String> parentsHash) {
this.parentsHash = parentsHash;
}

Expand Down

0 comments on commit dbccbd3

Please sign in to comment.