code: async def _register(self):
          
          if self.registered:
              self.logger.debug("skipping cap registration, already registered!")
              return
  
          # Ask server to list capabilities.
          await self.rawmsg('CAP', 'LS', '302')
  
          # Register as usual.
          await super()._register()
docs: Hijack registration to send a CAP LS first.