def raiseDictEvent(event, *args):
    """Raise a specific event and return result as a dictionnary

    Any additional keyword argument will be passed to registered
    CALLBACKS. Callback answers must be dictionnaries.

    :param event: the event to raise
    :return: a dictionnary
    """
    result = {}
    if EVENTS not in event or event not in CALLBACKS:
        return result
    for callback in CALLBACKS[event].values():
        tmp = callback(*args)
        if tmp is None:
            # Callback is registered but associated extension is
            # disabled.
            continue
        for k, v in tmp.iteritems():
            result[k] = v
    return result
dataset/ETHPy150Open tonioo/modoboa/modoboa/lib/events.py/raiseDictEvent/swapped operands of `not in`