Skip to content

Commit

Permalink
Fix null values during ChangeViewReason (neo-project#1016)
Browse files Browse the repository at this point in the history
  • Loading branch information
belane authored and Tommo-L committed Jun 22, 2020
1 parent 601bb47 commit b1f078d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion neo/Consensus/ConsensusService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,7 @@ private void OnTimer(Timer timer)
{
var reason = ChangeViewReason.Timeout;

if (context.Block != null && context.TransactionHashes.Count() > context.Transactions.Count)
if (context.Block != null && context.TransactionHashes?.Count() > context.Transactions?.Count)
{
reason = ChangeViewReason.TxNotFound;
}
Expand Down

0 comments on commit b1f078d

Please sign in to comment.