Skip to content

Commit

Permalink
popmd: remove unused 'handle' func and return err in connectBFG (#124)
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuasing authored May 20, 2024
1 parent fa2a4c4 commit cf7c570
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions service/popm/popm.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import (
"encoding/hex"
"errors"
"fmt"
"net/http"
"slices"
"strings"
"sync"
Expand Down Expand Up @@ -663,11 +662,6 @@ func (m *Miner) promRunning() float64 {
return 0
}

func handle(service string, mux *http.ServeMux, pattern string, handler func(http.ResponseWriter, *http.Request)) {
mux.HandleFunc(pattern, handler)
log.Infof("handle (%v): %v", service, pattern)
}

func (m *Miner) handleBFGCallCompletion(parrentCtx context.Context, conn *protocol.Conn, bc bfgCmd) {
log.Tracef("handleBFGCallCompletion")
defer log.Tracef("handleBFGCallCompletion exit")
Expand Down Expand Up @@ -805,7 +799,7 @@ func (m *Miner) connectBFG(pctx context.Context) error {
log.Debugf("Connected to BFG: %s", m.cfg.BFGWSURL)
m.bfgWg.Wait()

return nil
return err
}

func (m *Miner) bfg(ctx context.Context) error {
Expand Down

0 comments on commit cf7c570

Please sign in to comment.