def validate(self, request: Request):
     operation = request.operation
     if operation[TXN_TYPE] == SET_FEES:
         validate_multi_sig_txn(request, TRUSTEE, self.domain_state,
                                self.MinSendersForFees)
     else:
         super().validate(request)
Пример #2
0
    def validate(self, request: Request):
        req_type = request.operation[TXN_TYPE]
        if req_type == MINT_PUBLIC:
            return validate_multi_sig_txn(request, TRUSTEE, self.domain_state,
                                          self.MinSendersForPublicMint)

        elif req_type == XFER_PUBLIC:
            return self.handle_xfer_public_txn(request)

        raise InvalidClientMessageException(
            request.identifier, getattr(request, 'reqId', None),
            'Unsupported request type - {}'.format(req_type))