Skip to content

Commit

Permalink
Merge branch '0.5.0' of https://github.com/mikeluxue/trident into 0.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
angrynurd committed Apr 12, 2023
2 parents 11bbd5a + c48cfb5 commit e3779e5
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,9 @@ private TransactionCapsule createTransactionCapsuleWithoutValidate(
byte[] blockHash = Utils.getBlockId(solidHeadBlock).getBytes();
trx.setReference(solidHeadBlock.getBlockHeader().getRawData().getNumber(), blockHash);

long expiration = solidHeadBlock.getBlockHeader().getRawData().getTimestamp() + TRANSACTION_DEFAULT_EXPIRATION_TIME;
//get expiration time from head block timestamp
BlockExtention headBlock = blockingStub.getNowBlock2(EmptyMessage.getDefaultInstance());
long expiration = headBlock.getBlockHeader().getRawData().getTimestamp() + TRANSACTION_DEFAULT_EXPIRATION_TIME;
trx.setExpiration(expiration);
trx.setTimestamp();

Expand Down

0 comments on commit e3779e5

Please sign in to comment.