Commit 8cd03625 authored by Jon Pugh's avatar Jon Pugh

Load all context properties into Configuration->process()

parent 62be7be5
...@@ -125,10 +125,15 @@ class Configuration { ...@@ -125,10 +125,15 @@ class Configuration {
* This is a stub to be implemented by subclasses. * This is a stub to be implemented by subclasses.
*/ */
function process() { function process() {
if (is_object($this->store)) { if (!empty($this->context->getProperties())) {
$this->data['records'] = array_filter(array_merge($this->store->loaded_records, $this->store->records)); $this->data = $this->context->getProperties();
} }
return TRUE;
// @TODO: Remove legacy code.
// if (is_object($this->store)) {
// $this->data['records'] = array_filter(array_merge($this->store->loaded_records, $this->store->records));
// }
// return TRUE;
} }
/** /**
......
...@@ -34,16 +34,14 @@ class ServerConfiguration extends Configuration { ...@@ -34,16 +34,14 @@ class ServerConfiguration extends Configuration {
} }
function process() function process()
{ {
parent::process();
$app_dir = $this->context->console_config['config_path'] . '/' . $this->service->getType(); $app_dir = $this->context->console_config['config_path'] . '/' . $this->service->getType();
$this->data['http_port'] = $this->service->properties['http_port']; $this->data['http_port'] = $this->service->properties['http_port'];
$this->data['include_statement'] = '# INCLUDE STATEMENT'; $this->data['include_statement'] = '# INCLUDE STATEMENT';
$this->data['http_pred_path'] = "{$app_dir}/pre.d"; $this->data['http_pred_path'] = "{$app_dir}/pre.d";
$this->data['http_postd_path'] = "{$app_dir}/post.d"; $this->data['http_postd_path'] = "{$app_dir}/post.d";
$this->data['http_platformd_path'] = "{$app_dir}/platform.d"; $this->data['http_platformd_path'] = "{$app_dir}/platform.d";
$this->data['http_vhostd_path'] = "{$app_dir}/vhost.d"; $this->data['http_vhostd_path'] = "{$app_dir}/vhost.d";
$this->data['extra_config'] = ""; $this->data['extra_config'] = "";
return parent::process();
} }
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment