Skip to content
Browse files

#2 load config in safe way

  • Loading branch information...
1 parent 93e5674 commit d05a3e79cba0dceb651ae79f5d16095611330821 @thousandsofthem thousandsofthem committed Mar 15, 2013
Showing with 5 additions and 3 deletions.
  1. +5 −3 IronCore.class.php
View
8 IronCore.class.php
@@ -11,7 +11,7 @@
*/
class IronCore{
- protected $core_version = '0.1.2';
+ protected $core_version = '0.1.3';
// should be overridden by child class
protected $client_version = null;
@@ -121,8 +121,10 @@ protected function getConfigData($config_file_or_options){
$this->loadFromEnv(strtoupper($this->product_name));
$this->loadFromEnv('IRON');
- $this->loadConfigFile(self::homeDir() . '.iron.ini');
- $this->loadConfigFile(self::homeDir() . '.iron.json');
+ if (!ini_get('open_basedir')){
+ $this->loadConfigFile(self::homeDir() . '.iron.ini');
+ $this->loadConfigFile(self::homeDir() . '.iron.json');
+ }
$this->loadFromHash($this->default_values);

0 comments on commit d05a3e7

Please sign in to comment.
Something went wrong with that request. Please try again.