forked from TrueCloudLab/frostfs-node
[#733] neofs-adm: read contracts on start
Fail early and reduce disk operations when reading from archive. Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
0b6350d463
commit
088c894f44
6 changed files with 105 additions and 107 deletions
|
@ -132,10 +132,7 @@ func (c *initializeContext) multiSign(tx *transaction.Transaction, accType strin
|
|||
|
||||
func (c *initializeContext) transferGASToProxy() error {
|
||||
gasHash := c.nativeHash(nativenames.Gas)
|
||||
proxyCs, err := c.readContract(proxyContract)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
proxyCs := c.getContract(proxyContract)
|
||||
|
||||
bal, err := c.Client.NEP17BalanceOf(gasHash, proxyCs.Hash)
|
||||
if err != nil || bal > 0 {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue