ソースを参照

:recycle: Cleanup unused code

Ettore Di Giacinto 3 年 前
コミット
e91f7a9acc

+ 0 - 1
pkg/blockchain/ledger.go

@@ -24,7 +24,6 @@ type Ledger struct {
 
 type Store interface {
 	Add(Block)
-	Reset()
 	Len() int
 	Last() Block
 }

+ 0 - 4
pkg/blockchain/store_disk.go

@@ -23,10 +23,6 @@ func (m *DiskStore) Add(b Block) {
 
 }
 
-func (m *DiskStore) Reset() {
-	m.chain.EraseAll()
-}
-
 func (m *DiskStore) Len() int {
 	count, err := m.chain.Read("index")
 	if err != nil {

+ 0 - 4
pkg/blockchain/store_memory.go

@@ -8,10 +8,6 @@ func (m *MemoryStore) Add(b Block) {
 	m.block = &b
 }
 
-func (m *MemoryStore) Reset() {
-	m.block = &Block{}
-}
-
 func (m *MemoryStore) Len() int {
 	return m.block.Index
 }