mirror of
https://github.com/processwire/processwire.git
synced 2025-08-13 18:24:57 +02:00
Update Config class to auto-generate a tableSalt when one is not available from the static configuration
This commit is contained in:
@@ -205,7 +205,13 @@ class Config extends WireData {
|
||||
$value = parent::get($key);
|
||||
if($value === null) {
|
||||
// runtime properties
|
||||
if($key === 'serverProtocol') $value = $this->serverProtocol();
|
||||
if($key === 'serverProtocol') {
|
||||
$value = $this->serverProtocol();
|
||||
} else if($key === 'tableSalt') {
|
||||
$value = parent::get('installed');
|
||||
if(!$value) $value = @filemtime($this->paths->assets . 'active.php');
|
||||
$this->data['tableSalt'] = $value;
|
||||
}
|
||||
}
|
||||
return $value;
|
||||
}
|
||||
|
Reference in New Issue
Block a user