# Path: cardinal/decorators.py
# def command(triggers):
#     if isinstance(triggers, str):
#         triggers = [triggers]
# 
#     if not isinstance(triggers, list):
#         raise TypeError("Command must be a trigger string or list of triggers")
# 
#     def wrap(f):
#         f.commands = triggers
#         return f
# 
#     return wrap
# 
# def help(lines):
#     # For backwards compatibility
#     if isinstance(lines, str):
#         lines = [lines]
# 
#     if not isinstance(lines, list):
#         raise TypeError("Help must be a help string or list of help strings")
# 
#     def wrap(f):
#         # Create help list or prepend to it
#         if not hasattr(f, 'help'):
#             f.help = lines
#         else:
#             f.help = lines + f.help
# 
#         return f
# 
#     return wrap


from datetime import datetime
from cardinal.decorators import command, help
        return uptime

    # Give the user a list of valid commands in the bot if no command is
    # provided. If a valid command is provided, return its help text
    @command(['help'])
    @help("Shows loaded commands or a specific command's help.")
    @help("Syntax: .help [command]")
    def cmd_help(self, cardinal, user, channel, msg):
        parameters = msg.split()
        if len(parameters) == 1:
            cardinal.sendMsg(
                channel,
                "Loaded commands: %s" % ', '.join(self._get_commands(cardinal))
            )
        else:
            command = parameters[1]
            help = self._get_command_help(cardinal, command)
            if isinstance(help, list):
                for help_line in help:
                    cardinal.sendMsg(channel, help_line)
            elif isinstance(help, str):
                cardinal.sendMsg(channel, help)
            else:
                cardinal.sendMsg(
                    channel,
                    "Unable to handle help string returned by module.")

    # Sends some basic meta information about the bot
    @command('info')
    @help("Gives some basic information about the bot.")

# Path: cardinal/decorators.py
# def command(triggers):
#     if isinstance(triggers, str):
#         triggers = [triggers]
# 
#     if not isinstance(triggers, list):
#         raise TypeError("Command must be a trigger string or list of triggers")
# 
#     def wrap(f):
#         f.commands = triggers
#         return f
# 
#     return wrap
# 
# def help(lines):
#     # For backwards compatibility
#     if isinstance(lines, str):
#         lines = [lines]
# 
#     if not isinstance(lines, list):
#         raise TypeError("Help must be a help string or list of help strings")
# 
#     def wrap(f):
#         # Create help list or prepend to it
#         if not hasattr(f, 'help'):
#             f.help = lines
#         else:
#             f.help = lines + f.help
# 
#         return f
# 
#     return wrap


# Path: plugins/help/plugin.py
from datetime import datetime
from cardinal.decorators import command, help

        return uptime

    # Give the user a list of valid commands in the bot if no command is
    # provided. If a valid command is provided, return its help text
    @command(['help'])
    @help("Shows loaded commands or a specific command's help.")
    @help("Syntax: .help [command]")
    def cmd_help(self, cardinal, user, channel, msg):
        parameters = msg.split()
        if len(parameters) == 1:
            cardinal.sendMsg(
                channel,
                "Loaded commands: %s" % ', '.join(self._get_commands(cardinal))
            )
        else:
            command = parameters[1]
            help = self._get_command_help(cardinal, command)
            if isinstance(help, list):
                for help_line in help:
                    cardinal.sendMsg(channel, help_line)
            elif isinstance(help, str):
                cardinal.sendMsg(channel, help)
            else:
                cardinal.sendMsg(
                    channel,
                    "Unable to handle help string returned by module.")

    # Sends some basic meta information about the bot
    @command('info')
    @help("Gives some basic information about the bot.")

    @help("Syntax: .info")