aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/extension
diff options
context:
space:
mode:
authorDavid King <imkingdavid@gmail.com>2015-05-23 19:57:32 -0400
committerDavid King <imkingdavid@gmail.com>2015-05-23 19:57:32 -0400
commit9e6f9c8a64d89f48d531c5b24d535025dd04f956 (patch)
treed1f72147a9449e4e839ca9359166d1f330cd9f3e /phpBB/phpbb/extension
parent715d365a5e776207e1dddac7e5ccc50aad5621f1 (diff)
downloadforums-9e6f9c8a64d89f48d531c5b24d535025dd04f956.tar
forums-9e6f9c8a64d89f48d531c5b24d535025dd04f956.tar.gz
forums-9e6f9c8a64d89f48d531c5b24d535025dd04f956.tar.bz2
forums-9e6f9c8a64d89f48d531c5b24d535025dd04f956.tar.xz
forums-9e6f9c8a64d89f48d531c5b24d535025dd04f956.zip
[ticket/13733] Handle nonexistent classes as well
PHPBB3-13733
Diffstat (limited to 'phpBB/phpbb/extension')
-rw-r--r--phpBB/phpbb/extension/base.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/phpBB/phpbb/extension/base.php b/phpBB/phpbb/extension/base.php
index 4bf19b37ed..8b4d747eaf 100644
--- a/phpBB/phpbb/extension/base.php
+++ b/phpBB/phpbb/extension/base.php
@@ -139,8 +139,9 @@ class base implements \phpbb\extension\extension_interface
foreach ($migrations as $key => $migration)
{
- $reflector = new \ReflectionClass($migration);
- if (!$reflector->isSubclassOf('\phpbb\db\migration\migration')) {
+ // If the class doesn't exist OR the class does not extend the migration class
+ // we need to skip it.
+ if (!class_exists($migration) || ($reflector = new \ReflectionClass($migration) && !$reflector->isSubclassOf('\phpbb\db\migration\migration'))) {
unset($migrations[$key]);
}
}