Skip to content

Commit

Permalink
Added error condition of tn.SetConfig for debug
Browse files Browse the repository at this point in the history
  • Loading branch information
JoaoAndreSa committed Mar 12, 2020
1 parent c5dddb8 commit 7f37465
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion services/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package servicesunlynx

import (
"fmt"
"golang.org/x/xerrors"
"strconv"
"time"

Expand Down Expand Up @@ -416,7 +417,9 @@ func (s *Service) HandleQueryBroadcastFinished(recq *QueryBroadcastFinished) (ne

// NewProtocol creates a protocol instance executed by all nodes
func (s *Service) NewProtocol(tn *onet.TreeNodeInstance, conf *onet.GenericConfig) (onet.ProtocolInstance, error) {
tn.SetConfig(conf)
if err := tn.SetConfig(conf); err != nil {
return nil, xerrors.Errorf("couldn't set config: %+v", err)
}

var pi onet.ProtocolInstance
target := SurveyID(string(conf.Data))
Expand Down

0 comments on commit 7f37465

Please sign in to comment.