@Override
    public boolean deleteConsentDecisions(final String principal) {
        val query = new Query(Criteria.where("principal").is(principal));
        val result = this.mongoTemplate.remove(query, ConsentDecision.class, this.collectionName);
        return result.getDeletedCount() > 0;
    }
This is {@link MongoDbConsentRepository}.

@author Misagh Moayyed
@since 5.2.0
support/cas-server-support-consent-mongo/src/main/java/org/apereo/cas/consent/MongoDbConsentRepository.java