Separate style and phpBB versions in style.cfg #706

Merged
merged 2 commits into from Apr 19, 2012
View
2 phpBB/includes/acp/acp_styles.php
@@ -1056,7 +1056,7 @@ public function sort_styles($style1, $style2)
*/
protected function read_style_cfg($dir)
{
- static $required = array('name', 'version', 'copyright');
+ static $required = array('name', 'phpbb_version', 'copyright');
@callumacrae
callumacrae Apr 4, 2012

Why not require style_version, too?

@cyberalien
cyberalien Apr 4, 2012

style_version is only for style author's reference, it isn't used anywhere in phpBB, so I don't see a point in making it mandatory.

@callumacrae
callumacrae Apr 4, 2012

True, but it could be used in the future, right?

$cfg = parse_cfg_file($this->styles_path . $dir . '/style.cfg');
// Check if it is a valid file
View
3 phpBB/styles/prosilver/style.cfg
@@ -18,7 +18,8 @@
# General Information about this style
name = prosilver
copyright = © phpBB Group, 2007
-version = 3.1.0-dev
+style_version = 3.1.0-dev
+phpbb_version = 3.1.0-dev
# Defining a different template bitfield
# template_bitfield = lNg=
View
3 phpBB/styles/subsilver2/style.cfg
@@ -18,7 +18,8 @@
# General Information about this style
name = subsilver2
copyright = © 2005 phpBB Group
-version = 3.1.0-dev
+style_version = 3.1.0-dev
+phpbb_version = 3.1.0-dev
# Defining a different template bitfield
# template_bitfield = lNg=