fix quota info (#5040)
This commit is contained in:
+5
-1
@@ -71,10 +71,14 @@ func mainQuotaInfo(ctx *cli.Context) error {
|
||||
_, targetURL := url2Alias(args[0])
|
||||
qCfg, e := client.GetBucketQuota(globalContext, targetURL)
|
||||
fatalIf(probe.NewError(e).Trace(args...), "Unable to get bucket quota")
|
||||
sz := qCfg.Quota
|
||||
if qCfg.Size > 0 {
|
||||
sz = qCfg.Size
|
||||
}
|
||||
printMsg(quotaMessage{
|
||||
op: ctx.Command.Name,
|
||||
Bucket: targetURL,
|
||||
Quota: qCfg.Quota,
|
||||
Quota: sz,
|
||||
QuotaType: string(qCfg.Type),
|
||||
Status: "success",
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user