mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-16 22:51:23 +02:00
[ticket/14831] Make sure migrations always start with backslash
The migration system expects every migration to start with a backslash. If depends on definitions do not supply that leading backslash, we should make sure it's added manually before calling the depends on migration. PHPBB3-14831
This commit is contained in:
@@ -264,6 +264,9 @@ class migrator
|
|||||||
|
|
||||||
foreach ($state['migration_depends_on'] as $depend)
|
foreach ($state['migration_depends_on'] as $depend)
|
||||||
{
|
{
|
||||||
|
// Make sure migration starts with backslash
|
||||||
|
$depend = $depend[0] == '\\' ? $depend : '\\' . $depend;
|
||||||
|
|
||||||
if ($this->unfulfillable($depend) !== false)
|
if ($this->unfulfillable($depend) !== false)
|
||||||
{
|
{
|
||||||
throw new \phpbb\db\migration\exception('MIGRATION_NOT_FULFILLABLE', $name, $depend);
|
throw new \phpbb\db\migration\exception('MIGRATION_NOT_FULFILLABLE', $name, $depend);
|
||||||
|
Reference in New Issue
Block a user