fix(types/mempool): fix slice init length (#21494)

Signed-off-by: dropbigfish <fillfish@foxmail.com>
Co-authored-by: Julien Robert <julien@rbrt.fr>
This commit is contained in:
dropbigfish 2024-09-03 21:46:47 +08:00 committed by GitHub
parent 62bf23a5ae
commit 7bf0442748
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -71,7 +71,7 @@ func (a signerExtractionAdapter) GetSigners(tx sdk.Tx) ([]mempool.SignerData, er
if err != nil {
return nil, err
}
signerData := make([]mempool.SignerData, len(sigs))
signerData := make([]mempool.SignerData, 0, len(sigs))
for _, sig := range sigs {
signerData = append(signerData, mempool.SignerData{
Signer: sig.PubKey.Address().Bytes(),