1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-06 16:56:44 +02:00

[ticket/10824] Make styles use composer.json files

PHPBB3-10824
This commit is contained in:
Joas Schilling
2015-09-05 16:45:01 +02:00
committed by Marc Alexander
parent cd74556058
commit a200446646
7 changed files with 80 additions and 74 deletions

View File

@@ -344,7 +344,7 @@ class service
$parsed_array = array();
}
$filename = $this->phpbb_root_path . 'styles/' . $style['style_path'] . '/style.cfg';
$filename = $this->phpbb_root_path . 'styles/' . $style['style_path'] . '/composer.json';
if (!file_exists($filename))
{
@@ -354,7 +354,8 @@ class service
if (!isset($parsed_array['filetime']) || (($this->config['load_tplcompile'] && @filemtime($filename) > $parsed_array['filetime'])))
{
// Re-parse cfg file
$parsed_array = parse_cfg_file($filename);
$json = file_get_contents($filename);
$parsed_array = json_decode($json, true);
$parsed_array['filetime'] = @filemtime($filename);
$this->driver->put('_cfg_' . $style['style_path'], $parsed_array);