Skip to content

Commit aca9e1d

Browse files
committed
fixup! tapdb+universe: consolidate code, link commitment to previous one
1 parent dba7ba2 commit aca9e1d

File tree

2 files changed

+0
-36
lines changed

2 files changed

+0
-36
lines changed

universe/supplycommit/env.go

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -542,20 +542,6 @@ type StateMachineStore interface {
542542
// found, it returns an empty slice and no error.
543543
BindDanglingUpdatesToTransition(context.Context,
544544
asset.Specifier) ([]SupplyUpdateEvent, error)
545-
546-
// FetchCommitmentByOutpoint fetches a supply commitment by its outpoint
547-
// and group key. If no commitment is found, it returns
548-
// ErrCommitmentNotFound.
549-
FetchCommitmentByOutpoint(ctx context.Context,
550-
assetSpec asset.Specifier,
551-
outpoint wire.OutPoint) (*RootCommitment, error)
552-
553-
// FetchCommitmentBySpentOutpoint fetches a supply commitment by the
554-
// outpoint it spent and group key. If no commitment is found, it
555-
// returns ErrCommitmentNotFound.
556-
FetchCommitmentBySpentOutpoint(ctx context.Context,
557-
assetSpec asset.Specifier,
558-
spentOutpoint wire.OutPoint) (*RootCommitment, error)
559545
}
560546

561547
// SupplySyncer is an interface that allows the state machine to insert

universe/supplycommit/mock.go

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -344,28 +344,6 @@ func (m *mockStateMachineStore) BindDanglingUpdatesToTransition(
344344
return args.Get(0).([]SupplyUpdateEvent), args.Error(1)
345345
}
346346

347-
func (m *mockStateMachineStore) FetchCommitmentByOutpoint(ctx context.Context,
348-
assetSpec asset.Specifier,
349-
outpoint wire.OutPoint) (*RootCommitment, error) {
350-
351-
args := m.Called(ctx, assetSpec, outpoint)
352-
if args.Get(0) == nil {
353-
return nil, args.Error(1)
354-
}
355-
return args.Get(0).(*RootCommitment), args.Error(1)
356-
}
357-
358-
func (m *mockStateMachineStore) FetchCommitmentBySpentOutpoint(
359-
ctx context.Context, assetSpec asset.Specifier,
360-
spentOutpoint wire.OutPoint) (*RootCommitment, error) {
361-
362-
args := m.Called(ctx, assetSpec, spentOutpoint)
363-
if args.Get(0) == nil {
364-
return nil, args.Error(1)
365-
}
366-
return args.Get(0).(*RootCommitment), args.Error(1)
367-
}
368-
369347
// mockDaemonAdapters is a mock implementation of the protofsm.DaemonAdapters
370348
// interface.
371349
type mockDaemonAdapters struct {

0 commit comments

Comments
 (0)