From 2f6171aeccca6d5bf1098f88a6a747c984d3e009 Mon Sep 17 00:00:00 2001 From: gVisor bot Date: Tue, 8 Nov 2022 22:30:50 +0800 Subject: [PATCH] fix: subscriptionInfo api --- adapter/provider/subscription_info.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/adapter/provider/subscription_info.go b/adapter/provider/subscription_info.go index 2f6f5446..fc6992e2 100644 --- a/adapter/provider/subscription_info.go +++ b/adapter/provider/subscription_info.go @@ -7,10 +7,10 @@ import ( ) type SubscriptionInfo struct { - Upload uint64 - Download uint64 - Total uint64 - Expire uint64 + Upload int64 + Download int64 + Total int64 + Expire int64 } func NewSubscriptionInfo(str string) (si *SubscriptionInfo, err error) { @@ -51,7 +51,7 @@ func NewSubscriptionInfo(str string) (si *SubscriptionInfo, err error) { return } -func str2uint64(str string) (uint64, error) { +func str2uint64(str string) (int64, error) { i, err := strconv.ParseInt(str, 10, 64) - return uint64(i), err + return i, err }