From 38217e757184aeccb50ff22abe7dd7d82b6d3a4e Mon Sep 17 00:00:00 2001 From: Mr Chen Date: Mon, 10 Jun 2024 00:40:17 +0800 Subject: [PATCH] Update index.py --- plugins/mysql-apt/index.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/plugins/mysql-apt/index.py b/plugins/mysql-apt/index.py index a6d426d5a..56695560d 100755 --- a/plugins/mysql-apt/index.py +++ b/plugins/mysql-apt/index.py @@ -1984,9 +1984,8 @@ def addMasterRepSlaveUser(version=''): if not data[0]: return data[1] - if not 'address' in args: - address = '' - else: + address = '' + if 'address' in args: address = args['address'].strip() username = args['username'].strip() @@ -2979,9 +2978,6 @@ if __name__ == "__main__": if os.path.exists(version_pl): version = mw.readFile(version_pl).strip() - if (len(sys.argv) > 2): - version = sys.argv[2] - if func == 'status': print(status(version)) elif func == 'start':