aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/event/md_exporter.php
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@gmx.de>2014-04-20 15:55:24 +0200
committerJoas Schilling <nickvergessen@gmx.de>2014-04-24 16:51:39 +0200
commitf676f50c22a2e8d4a6c5671c5cf2f9f7372ed40d (patch)
treeccf0247aae126b65b4b47dd7df41cbbf64846195 /phpBB/phpbb/event/md_exporter.php
parent23dbddc59d864a71d99b1fd024533cb24ffff626 (diff)
downloadforums-f676f50c22a2e8d4a6c5671c5cf2f9f7372ed40d.tar
forums-f676f50c22a2e8d4a6c5671c5cf2f9f7372ed40d.tar.gz
forums-f676f50c22a2e8d4a6c5671c5cf2f9f7372ed40d.tar.bz2
forums-f676f50c22a2e8d4a6c5671c5cf2f9f7372ed40d.tar.xz
forums-f676f50c22a2e8d4a6c5671c5cf2f9f7372ed40d.zip
[ticket/12273] Only check selected files
PHPBB3-12273
Diffstat (limited to 'phpBB/phpbb/event/md_exporter.php')
-rw-r--r--phpBB/phpbb/event/md_exporter.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/phpBB/phpbb/event/md_exporter.php b/phpBB/phpbb/event/md_exporter.php
index 8714bdb2f7..089115b91f 100644
--- a/phpBB/phpbb/event/md_exporter.php
+++ b/phpBB/phpbb/event/md_exporter.php
@@ -198,7 +198,6 @@ class md_exporter
$files = explode("\n + ", $file_details);
foreach ($files as $file)
{
-
if (($this->filter !== 'adm') && strpos($file, 'styles/prosilver/template/') === 0)
{
$files_list['prosilver'][] = substr($file, strlen('styles/prosilver/template/'));
@@ -253,9 +252,13 @@ class md_exporter
$file_content = file_get_contents($this->root_path . $file);
foreach ($events as $event)
{
- if (strpos($file_content, '<!-- EVENT ' . $event . ' -->') === false)
+ if (($this->filter !== 'adm') && strpos($file, 'adm/style/') !== 0
+ || ($this->filter === 'adm') && strpos($file, 'adm/style/') === 0)
{
- throw new \LogicException("Event '{$event}' not found in file '{$file}'", 2);
+ if (strpos($file_content, '<!-- EVENT ' . $event . ' -->') === false)
+ {
+ throw new \LogicException("Event '{$event}' not found in file '{$file}'", 2);
+ }
}
}
}