From 81465a50d6fdeccdd7cce65a88e9973e422edf75 Mon Sep 17 00:00:00 2001 From: Yuri Kuznetsov Date: Tue, 8 Sep 2020 16:42:09 +0300 Subject: [PATCH] do not allow sub dirs for services --- application/Espo/Core/ServiceFactory.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/application/Espo/Core/ServiceFactory.php b/application/Espo/Core/ServiceFactory.php index 0ff9191b0c..5751906111 100644 --- a/application/Espo/Core/ServiceFactory.php +++ b/application/Espo/Core/ServiceFactory.php @@ -50,15 +50,17 @@ class ServiceFactory protected function getClassName(string $name) { - return $this->classFinder->find('Services', $name, true); + return $this->classFinder->find('Services', $name); } public function checkExists(string $name) : bool { $className = $this->getClassName($name); + if (!$className) { return false; } + return true; }