Skip to content
This repository has been archived by the owner on Apr 2, 2024. It is now read-only.

Commit

Permalink
Fix for xpub issue with increment field
Browse files Browse the repository at this point in the history
  • Loading branch information
mrz1836 committed May 16, 2022
1 parent d4a32b0 commit 3e96eef
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions model_xpubs.go
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,6 @@ func (m *Xpub) incrementNextNum(ctx context.Context, chain uint32) (uint32, erro
}

// Try to increment the field
// incrementXPub := newXpubUsingID(m.ID, m.GetOptions(false)...)
if newNum, err = incrementField(
ctx, m, fieldName, 1,
); err != nil {
Expand Down Expand Up @@ -259,7 +258,6 @@ func (m *Xpub) AfterCreated(ctx context.Context) error {
// todo: run these in go routines?

// Store in the cache
m.DebugLog("saving xpub to cache: " + fmt.Sprintf("%+v\n", m))
if err := saveToCache(
ctx, []string{fmt.Sprintf(cacheKeyXpubModel, m.GetID())}, m, 0,
); err != nil {
Expand All @@ -275,7 +273,6 @@ func (m *Xpub) AfterUpdated(ctx context.Context) error {
m.DebugLog("starting: " + m.Name() + " AfterUpdated hook...")

// Store in the cache
m.DebugLog("saving xpub to cache: " + fmt.Sprintf("%+v\n", m))
if err := saveToCache(
ctx, []string{fmt.Sprintf(cacheKeyXpubModel, m.GetID())}, m, 0,
); err != nil {
Expand Down

0 comments on commit 3e96eef

Please sign in to comment.