From ce626c763e13d1942cec7ac25d0b4b9f3f955082 Mon Sep 17 00:00:00 2001
From: Konstantin Tsabolov <konstantin.tsabolov@spherity.com>
Date: Wed, 21 Feb 2024 11:20:23 +0100
Subject: [PATCH] chore: return false if a policy was not specified

---
 apps/credential-manager/src/policies/policies.service.ts | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/apps/credential-manager/src/policies/policies.service.ts b/apps/credential-manager/src/policies/policies.service.ts
index 5eb160a..4872efc 100644
--- a/apps/credential-manager/src/policies/policies.service.ts
+++ b/apps/credential-manager/src/policies/policies.service.ts
@@ -56,7 +56,7 @@ export class PoliciesService {
 
   public checkAutoReissue(tenantId: string, credentialId: string) {
     if (!this.policiesParams.autoReissue.policy) {
-      return { result: true };
+      return { result: false };
     }
 
     return this.evaluatePolicy(
@@ -68,7 +68,7 @@ export class PoliciesService {
 
   public checkAutoRevocation(tenantId: string, credentialId: string) {
     if (!this.policiesParams.autoRevocation.policy) {
-      return { result: true };
+      return { result: false };
     }
 
     return this.evaluatePolicy(
@@ -80,7 +80,7 @@ export class PoliciesService {
 
   public checkRefresh(tenantId: string, credentialId: string) {
     if (!this.policiesParams.refresh.policy) {
-      return { result: true };
+      return { result: false };
     }
 
     return this.evaluatePolicy(
-- 
GitLab