aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/db/migration/tool/module.php
diff options
context:
space:
mode:
authorrxu <rxu@mail.ru>2016-10-24 01:41:24 +0700
committerrxu <rxu@mail.ru>2016-10-24 01:41:24 +0700
commit77f1bac64bd00a581f71dccbb20b532ff1ec2434 (patch)
treeda5633d31744441cc8ac8058e51c802078146f2b /phpBB/phpbb/db/migration/tool/module.php
parent849cd74700bc1425245ae9a8c5ec5f126d7a61ff (diff)
downloadforums-77f1bac64bd00a581f71dccbb20b532ff1ec2434.tar
forums-77f1bac64bd00a581f71dccbb20b532ff1ec2434.tar.gz
forums-77f1bac64bd00a581f71dccbb20b532ff1ec2434.tar.bz2
forums-77f1bac64bd00a581f71dccbb20b532ff1ec2434.tar.xz
forums-77f1bac64bd00a581f71dccbb20b532ff1ec2434.zip
[ticket/14831] Optimize code construction
PHPBB3-14831
Diffstat (limited to 'phpBB/phpbb/db/migration/tool/module.php')
-rw-r--r--phpBB/phpbb/db/migration/tool/module.php8
1 files changed, 3 insertions, 5 deletions
diff --git a/phpBB/phpbb/db/migration/tool/module.php b/phpBB/phpbb/db/migration/tool/module.php
index a543fd5cab..7ea7d1dac1 100644
--- a/phpBB/phpbb/db/migration/tool/module.php
+++ b/phpBB/phpbb/db/migration/tool/module.php
@@ -91,14 +91,12 @@ class module implements \phpbb\db\migration\tool\tool_interface
if ($parent !== false)
{
$parent = $this->get_parent_module_id($parent, $module, false);
- if ($parent !== false)
- {
- $parent_sql = 'AND parent_id = ' . (int) $parent;
- }
- else
+ if ($parent === false)
{
return false;
}
+
+ $parent_sql = 'AND parent_id = ' . (int) $parent;
}
$sql = 'SELECT module_id