From 65c433407dc02aff90fc41f63ea46b372b374b9b Mon Sep 17 00:00:00 2001 From: Andrew Chen Wang <60190294+Andrew-Chen-Wang@users.noreply.github.com> Date: Thu, 14 Oct 2021 09:36:09 -0400 Subject: Simplify MODULE LOAD and fix SCRIPT FLUSH doc (#1597) --- redis/commands.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'redis') diff --git a/redis/commands.py b/redis/commands.py index 7bb6b50..e10238a 100644 --- a/redis/commands.py +++ b/redis/commands.py @@ -2861,7 +2861,7 @@ class Commands: See: https://redis.io/commands/script-flush """ if sync_type not in ["SYNC", "ASYNC"]: - raise DataError("SCRIPT FLUSH defaults to SYNC or" + raise DataError("SCRIPT FLUSH defaults to SYNC or " "accepts SYNC/ASYNC") pieces = [sync_type] return self.execute_command('SCRIPT FLUSH', *pieces) @@ -3155,9 +3155,7 @@ class Commands: Passes all ``*args`` to the module, during loading. Raises ``ModuleError`` if a module is not found at ``path``. """ - pieces = list(args) - pieces.insert(0, path) - return self.execute_command('MODULE LOAD', *pieces) + return self.execute_command('MODULE LOAD', path, *args) def module_unload(self, name): """ -- cgit v1.2.1