From 2f079a0da77803c348b4d5484e049f8266e5ab85 Mon Sep 17 00:00:00 2001 From: hiddify Date: Thu, 18 May 2023 16:33:12 +0200 Subject: [PATCH] new: add reset to statsquery --- xtlsapi/api_services/stats/get_statsquery.py | 4 ++-- xtlsapi/singbox_api_services/stats/get_statsquery.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/xtlsapi/api_services/stats/get_statsquery.py b/xtlsapi/api_services/stats/get_statsquery.py index a7bd824..9abf379 100644 --- a/xtlsapi/api_services/stats/get_statsquery.py +++ b/xtlsapi/api_services/stats/get_statsquery.py @@ -5,11 +5,11 @@ class StatsQuery(BaseService): - def stats_query(self, pattern): + def stats_query(self, pattern,reset=False): try: return self.stats_stub.QueryStats( command_pb2.QueryStatsRequest( - pattern=pattern + pattern=pattern,reset=reset ) ).stat except grpc.RpcError: diff --git a/xtlsapi/singbox_api_services/stats/get_statsquery.py b/xtlsapi/singbox_api_services/stats/get_statsquery.py index 9334487..9bb3df2 100644 --- a/xtlsapi/singbox_api_services/stats/get_statsquery.py +++ b/xtlsapi/singbox_api_services/stats/get_statsquery.py @@ -5,11 +5,11 @@ class StatsQuery(BaseService): - def stats_query(self, pattern): + def stats_query(self, pattern,reset=False): try: return self.stats_stub.QueryStats( stats_pb2.QueryStatsRequest( - pattern=pattern + pattern=pattern,reset=reset ) ).stat except grpc.RpcError: