Aka: update listCommands override to only include built in cmds

The old behavior is superseded by 'aka list'. This makes it easier for people to find Aka plugin's core commands, as
'list Aka' won't be filled with random, irrelevant alias definitions.
This commit is contained in:
James Lu 2014-12-16 16:27:22 -08:00
parent fe778c60bf
commit f802f77904
1 changed files with 3 additions and 6 deletions

View File

@ -32,7 +32,6 @@ import re
import os
import sys
import datetime
import operator
import supybot.conf as conf
import supybot.utils as utils
@ -397,11 +396,9 @@ class Aka(callbacks.Plugin):
isCommand = isCommandMethod
def listCommands(self):
channel = dynamic.channel or 'global'
return list(set(list(map(callbacks.formatCommand,
self._db.get_aka_list(channel) +
self._db.get_aka_list('global'))) +
['add', 'remove', 'lock', 'unlock', 'importaliasdatabase']))
commands = ['add', 'remove', 'lock', 'unlock', 'importaliasdatabase',
'show', 'list', 'set']
return commands
def getCommand(self, args, check_other_plugins=True):
canonicalName = callbacks.canonicalName