fmt a bit

This commit is contained in:
whyrusleeping 2019-07-24 15:59:47 -07:00
parent 859471aeaf
commit abe5ce4cfe
3 changed files with 8 additions and 8 deletions

View File

@ -76,7 +76,7 @@ var runCmd = &cli.Command{
ah := &auth.Handler{
Verify: minerapi.AuthVerify,
Next: rpcServer.ServeHTTP,
Next: rpcServer.ServeHTTP,
}
http.Handle("/rpc/v0", ah)

View File

@ -14,7 +14,7 @@ func serveRPC(a api.FullNode, addr string) error {
ah := &auth.Handler{
Verify: a.AuthVerify,
Next: rpcServer.ServeHTTP,
Next: rpcServer.ServeHTTP,
}
http.Handle("/rpc/v0", ah)

View File

@ -67,7 +67,7 @@ type client struct {
namespace string
requests chan clientRequest
idCtr int64
idCtr int64
}
// NewMergeClient is like NewClient, but allows to specify multiple structs
@ -143,7 +143,7 @@ func (c *client) makeOutChan(ctx context.Context, ftyp reflect.Type, valOut int)
}
ch.Send(val.Elem()) // todo: select on ctx is probably a good idea
}
}
}
return func() reflect.Value { return retVal }, chCtor
@ -192,12 +192,12 @@ type rpcFunc struct {
ftyp reflect.Type
name string
nout int
nout int
valOut int
errOut int
hasCtx int
retCh bool
retCh bool
}
func (fn *rpcFunc) processResponse(resp clientResponse, rval reflect.Value) []reflect.Value {
@ -290,8 +290,8 @@ func (c *client) makeRpcFunc(f reflect.StructField) (reflect.Value, error) {
fun := &rpcFunc{
client: c,
ftyp: ftyp,
name: f.Name,
ftyp: ftyp,
name: f.Name,
}
fun.valOut, fun.errOut, fun.nout = processFuncOut(ftyp)