Browse Source

Ensure that commands are registered in server profiles using lowercase aliases.

Daniele Alessandri 13 years ago
parent
commit
68dba4cb12
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lib/Predis/Profiles/ServerProfile.php

+ 1 - 1
lib/Predis/Profiles/ServerProfile.php

@@ -99,7 +99,7 @@ abstract class ServerProfile implements IServerProfile, IProcessingSupport {
         if (!$commandReflection->isSubclassOf('\Predis\Commands\ICommand')) {
             throw new ClientException("Cannot register '$command' as it is not a valid Redis command");
         }
-        $this->_registeredCommands[$alias] = $command;
+        $this->_registeredCommands[strtolower($alias)] = $command;
     }
 
     public function setProcessor(ICommandProcessor $processor) {