Skip to content

Commit

Permalink
eosfs: Fix two minor warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
Fabrizio Furano committed Mar 19, 2021
1 parent 9423a36 commit 91cb5c4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pkg/eosclient/eosgrpc/eosgrpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ type Client struct {
cl erpc.EosClient
}

// GetHttpCl creates an http client for immediate usage, using the already instantiated resources
// GetHTTPCl creates an http client for immediate usage, using the already instantiated resources
func (c *Client) GetHTTPCl() *ehttp.EosHttpClient {
return ehttp.New(&c.opt.httpopts)
}
Expand Down Expand Up @@ -704,8 +704,9 @@ func (c *Client) GetQuota(ctx context.Context, username, rootUID, rootGID, path
// If there are many for this node, we sum them up
for i := 0; i < len(resp.Quota.Quotanode); i++ {
log.Debug().Str("func", "GetQuota").Str("rootuid,rootgid", rootUID+","+rootGID).Str("quotanode:", fmt.Sprintf("%d: %#v", i, resp.Quota.Quotanode[i])).Msg("")
var mx uint64

mx := resp.Quota.Quotanode[i].Maxlogicalbytes - resp.Quota.Quotanode[i].Usedbytes
mx = resp.Quota.Quotanode[i].Maxlogicalbytes - resp.Quota.Quotanode[i].Usedbytes
if mx < 0 {
mx = 0
}
Expand Down

0 comments on commit 91cb5c4

Please sign in to comment.