Skip to content

EspoCRM – Open Source CRM Application

Fix before upgrade check

Yurii96689e8d33c6
diff --git a/upgrades/10.0/scripts/BeforeUpgrade.php b/upgrades/10.0/scripts/BeforeUpgrade.php
index ac85a3e635..a65aafa528 100644
--- a/upgrades/10.0/scripts/BeforeUpgrade.php
+++ b/upgrades/10.0/scripts/BeforeUpgrade.php
@@ -178,7 +178,11 @@ class BeforeUpgrade
return false;
}
- return (new ReflectionMethod($child, $method))->getDeclaringClass()->getName() !== $base;
+ $methodRef = new ReflectionMethod($child, $method);
+
+ return
+ $methodRef->getDeclaringClass()->getName() !== $base &&
+ $methodRef->getDeclaringClass()->getName() === $child;
}
/**