MCPcopy Create free account
hub / github.com/CPChain/chain / Overlaps

Method Overlaps

core/tx_list.go:293–295  ·  view source on GitHub ↗

Overlaps returns whether the transaction specified has the same nonce as one already contained within the list.

(tx *types.Transaction)

Source from the content-addressed store, hash-verified

291// Overlaps returns whether the transaction specified has the same nonce as one
292// already contained within the list.
293func (l *txList) Overlaps(tx *types.Transaction) bool {
294 return l.txs.Get(tx.Nonce()) != nil
295}
296
297// Add tries to insert a new transaction into the list, returning whether the
298// transaction was accepted, and if yes, any previous transaction it replaced.

Callers 1

addMethod · 0.80

Calls 2

GetMethod · 0.65
NonceMethod · 0.65

Tested by

no test coverage detected