code: def getRemote(self, name: str = None, ha: HA = None):
          
          return self.findInRemotesByName(name) if name else \
              self.findInRemotesByHA(ha)
docs: Find the remote by name or ha.
  
          :param name: the name of the remote to find
          :param ha: host address pair the remote to find
          :raises: RemoteNotFound