Commit 9f94cfd0 by JustSong

fix: fix used amount not correct

parent 27d33d23
...@@ -48,6 +48,9 @@ func GetUsage(c *gin.Context) { ...@@ -48,6 +48,9 @@ func GetUsage(c *gin.Context) {
return return
} }
amount := float64(quota) amount := float64(quota)
if common.DisplayInCurrencyEnabled {
amount /= common.QuotaPerUnit
}
usage := OpenAIUsageResponse{ usage := OpenAIUsageResponse{
Object: "list", Object: "list",
TotalUsage: amount, TotalUsage: amount,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment