Skip to content

Commit 3ad9a6b

Browse files
chore: minor refactoring of guard statements
1 parent 4330304 commit 3ad9a6b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

Sources/web3swift/Tokens/ERC20/ERC20BasePropertiesProvider.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,7 @@ public final class ERC20BasePropertiesProvider {
2121
}
2222

2323
public func readProperties() async throws {
24-
guard !hasReadProperties else { return }
25-
guard contract.contract.address != nil else {return}
24+
guard !hasReadProperties && contract.contract.address != nil else { return }
2625
name = try await contract
2726
.createReadOperation("name")?
2827
.callContractMethod()["0"] as? String

0 commit comments

Comments
 (0)