summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/components/application_manager/src/policies/policy_handler.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/components/application_manager/src/policies/policy_handler.cc b/src/components/application_manager/src/policies/policy_handler.cc
index 202b62ced4..500981a5a8 100644
--- a/src/components/application_manager/src/policies/policy_handler.cc
+++ b/src/components/application_manager/src/policies/policy_handler.cc
@@ -2869,6 +2869,10 @@ void PolicyHandler::UpdateHMILevel(ApplicationSharedPtr app,
bool PolicyHandler::CheckModule(const PTString& app_id,
const PTString& module) {
+ if (!PolicyEnabled()) {
+ SDL_LOG_DEBUG("Policy table is disabled");
+ return true;
+ }
const auto policy_manager = LoadPolicyManager();
POLICY_LIB_CHECK_OR_RETURN(policy_manager, false);
return policy_manager->CheckModule(app_id, module);
@@ -2939,6 +2943,10 @@ bool PolicyHandler::CheckHMIType(const std::string& application_id,
mobile_apis::AppHMIType::eType hmi,
const smart_objects::SmartObject* app_types) {
SDL_LOG_AUTO_TRACE();
+ if (!PolicyEnabled()) {
+ SDL_LOG_DEBUG("Policy table is disabled");
+ return true;
+ }
const auto policy_manager = LoadPolicyManager();
POLICY_LIB_CHECK_OR_RETURN(policy_manager, false);
std::vector<int> policy_hmi_types;