| Conditions | 3 |
| Paths | 3 |
| Total Lines | 15 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 26 | public static function read($sConfigFile) |
||
| 27 | { |
||
| 28 | $sConfigFile = realpath($sConfigFile); |
||
| 29 | if(!is_readable($sConfigFile)) |
||
| 30 | { |
||
| 31 | throw new \Jaxon\Config\Exception\File(jaxon_trans('config.errors.file.access', array('path' => $sConfigFile))); |
||
| 32 | } |
||
| 33 | $aConfigOptions = include($sConfigFile); |
||
| 34 | if(!is_array($aConfigOptions)) |
||
| 35 | { |
||
| 36 | throw new \Jaxon\Config\Exception\File(jaxon_trans('config.errors.file.content', array('path' => $sConfigFile))); |
||
| 37 | } |
||
| 38 | |||
| 39 | return $aConfigOptions; |
||
| 40 | } |
||
| 41 | } |
||
| 42 |