analytics/views.py
def register(self, gadget):
        """
        Registers a gadget object.
        If a gadget is already registered, this will raise AlreadyRegistered.
        """
        if gadget in self._registry:
            raise AlreadyRegistered
        else:
            self._registry.append(gadget)
def register(self, gadget):
        if gadget in self._registry:
            raise AlreadyRegistered
        else:
            self._registry.append(gadget)
def register ( self , gadget ) : if gadget in self . _registry : raise AlreadyRegistered else : self . _registry . append ( gadget )
Registers a gadget object.
        If a gadget is already registered, this will raise AlreadyRegistered.
Registers a gadget object . If a gadget is already registered this will raise AlreadyRegistered .