Fixed registerCommands