Skip to content

Commit

Permalink
add theme check for prerequisites (backwards compatible)
Browse files Browse the repository at this point in the history
  • Loading branch information
dleffler committed Dec 20, 2017
1 parent 948daac commit a91b1ad
Showing 1 changed file with 9 additions and 0 deletions.
Expand Up @@ -1023,6 +1023,8 @@ public function manage_themes() {
if ($file != '.' && $file != '..' && is_dir(BASE."themes/$file") && is_readable(BASE."themes/$file/class.php")) {
include_once(BASE."themes/$file/class.php");
$theme = new $file();
if (method_exists($theme, 'supported') && !$theme->supported())
continue;
$t = new stdClass();
$t->user_configured = isset($theme->user_configured) ? $theme->user_configured : '';
$t->stock_theme = isset($theme->stock_theme) ? $theme->stock_theme : '';
Expand Down Expand Up @@ -1435,6 +1437,13 @@ function __construct($params = array()) {
$this->params = $params;
}

/**
* are all prerequisites available?
*/
function supported() {
return true;
}

/**
* Method to Configure theme settings
* This generic routine parses the theme's config.php file
Expand Down

0 comments on commit a91b1ad

Please sign in to comment.