projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
bd301e2
)
add timezone check to core system.
author
Alan
<alan@roojs.com>
Mon, 31 Jul 2023 04:23:04 +0000
(12:23 +0800)
committer
Alan
<alan@roojs.com>
Mon, 31 Jul 2023 04:23:04 +0000
(12:23 +0800)
Config.php
patch
|
blob
|
history
diff --git
a/Config.php
b/Config.php
index
f5144bc
..
9357316
100644
(file)
--- a/
Config.php
+++ b/
Config.php
@@
-21,7
+21,9
@@
class Pman_Core_Config {
function init($ff, $cfg)
{
function init($ff, $cfg)
{
-
+
+
+
$cfg = $this->overlayDefaults($cfg);
if (!empty($this->memory_limit)) {
$cfg = $this->overlayDefaults($cfg);
if (!empty($this->memory_limit)) {
@@
-31,8
+33,18
@@
class Pman_Core_Config {
}
}
}
}
+
$this->verifyExtensions();
$this->verifyExtensions();
+
+ if (!isset($cfg['Pman']['timezone'])) {
+ die("timezone needs setting in Pman[timezone]");
+ }
+ if ($cfg['Pman']['timezone'] != ini_get('date.timezone')) {
+ die("timezone needs setting in php.ini date.timezone = " . $cfg['Pman']['timezone']);
+ }
+
+
return $cfg;
}
return $cfg;
}