# -*- coding: utf-8 -*-
from pycobot.tables import User, UserPriv



class authadd:
    def __init__(self, core, client):
        core.addCommandHandler("antiflood", self, cpriv=5, chelp=
        "Maneja el antiflood de un canal. Sintaxis: antiflood <canal> <on/off>"
        " [mensajes] [segundos]", cprivchan=True)

    def antiflood_p(self, bot, cli, ev):
        if len(ev.splitd) > 2:
            return ev.splitd[1]
        else:
            return 0

    def antiflood(self, bot, cli, ev):
        if not len(ev.splitd) > 1:
            cli.privmsg(ev.target, "\00304Error\003: Faltan parametros.")
            return 0
        # TODO.
@@ -73,13 +73,15 @@
 ss a
-uthad
+ntifloo
 d:%0A 
@@ -635,11 +635,272 @@
     
-# TODO.
+%0A        if ev.splitd%5B1%5D == %22on%22:%0A            pass%0A        elif ev.splitd%5B1%5D == %22off%22:%0A            pass%0A        %0A%0Aclass AntiFloodChan(BaseModel):%0A    cid = IntegerField(primary_key=True)%0A    chan = CharField()%0A    ratesec = IntegerField()%0A    ratemsg = IntegerField()%0A

Update antiflood.py