From 4cb90ff0db7bf3e44832ec58c79701cf5a505ad7 Mon Sep 17 00:00:00 2001 From: Christopher Schuchardt Date: Sat, 7 Dec 2024 12:58:41 -0500 Subject: [PATCH] Added null check --- src/Neo/Extensions/SmartContract/GasTokenExtensions.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Neo/Extensions/SmartContract/GasTokenExtensions.cs b/src/Neo/Extensions/SmartContract/GasTokenExtensions.cs index ef1f4ea591..758e2bbb97 100644 --- a/src/Neo/Extensions/SmartContract/GasTokenExtensions.cs +++ b/src/Neo/Extensions/SmartContract/GasTokenExtensions.cs @@ -22,6 +22,9 @@ public static class GasTokenExtensions { public static IEnumerable<(UInt160 Address, BigInteger Balance)> GetAccounts(this GasToken gasToken, DataCache snapshot) { + if (gasToken is null) + throw new ArgumentNullException(nameof(gasToken)); + if (snapshot is null) throw new ArgumentNullException(nameof(snapshot));