aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_admin.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2007-05-07 21:13:18 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2007-05-07 21:13:18 +0000
commit383e27dba8057fbbafc83590bc6a98ce774b8634 (patch)
tree2bb7cafd6cb6a1195a6695923411ebb62c8097c1 /phpBB/includes/functions_admin.php
parent42ea2b5e2da2ef83a897c43ab11ef4d088e65823 (diff)
downloadforums-383e27dba8057fbbafc83590bc6a98ce774b8634.tar
forums-383e27dba8057fbbafc83590bc6a98ce774b8634.tar.gz
forums-383e27dba8057fbbafc83590bc6a98ce774b8634.tar.bz2
forums-383e27dba8057fbbafc83590bc6a98ce774b8634.tar.xz
forums-383e27dba8057fbbafc83590bc6a98ce774b8634.zip
#10627 - revert previous permission inclusion change, forgot that that permissions_phpbb indeed need to be added as the first file.
git-svn-id: file:///svn/phpbb/trunk@7502 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_admin.php')
-rw-r--r--phpBB/includes/functions_admin.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/phpBB/includes/functions_admin.php b/phpBB/includes/functions_admin.php
index 8581cc328d..96059191f0 100644
--- a/phpBB/includes/functions_admin.php
+++ b/phpBB/includes/functions_admin.php
@@ -2955,9 +2955,12 @@ function add_permission_language()
{
global $user, $phpEx;
+ // First of all, our own file. We need to include it as the first file because it presets all relevant variables.
+ $user->add_lang('acp/permissions_phpbb');
+
$files_to_add = array();
- // Search in acp and mods folder for permissions_ files.
+ // Now search in acp and mods folder for permissions_ files.
foreach (array('acp/', 'mods/') as $path)
{
$dh = @opendir($user->lang_path . $path);
@@ -2966,7 +2969,7 @@ function add_permission_language()
{
while (($file = readdir($dh)) !== false)
{
- if (strpos($file, 'permissions_') === 0 && substr($file, -(strlen($phpEx) + 1)) === '.' . $phpEx)
+ if ($file !== 'permissions_phpbb.' . $phpEx && strpos($file, 'permissions_') === 0 && substr($file, -(strlen($phpEx) + 1)) === '.' . $phpEx)
{
$files_to_add[] = $path . substr($file, 0, -(strlen($phpEx) + 1));
}