diff options
Diffstat (limited to 'lib/plugins/config')
-rw-r--r-- | lib/plugins/config/admin.php | 4 | ||||
-rw-r--r-- | lib/plugins/config/settings/config.class.php | 32 | ||||
-rw-r--r-- | lib/plugins/config/settings/extra.class.php | 2 |
3 files changed, 19 insertions, 19 deletions
diff --git a/lib/plugins/config/admin.php b/lib/plugins/config/admin.php index 9202a221b..2ef570b68 100644 --- a/lib/plugins/config/admin.php +++ b/lib/plugins/config/admin.php @@ -282,7 +282,7 @@ class admin_plugin_config extends DokuWiki_Admin_Plugin { if ($plugin == '.' || $plugin == '..' || $plugin == 'tmp' || $plugin == 'config') continue; if (is_file(DOKU_PLUGIN.$plugin)) continue; - if (@file_exists(DOKU_PLUGIN.$plugin.$enlangfile)){ + if (file_exists(DOKU_PLUGIN.$plugin.$enlangfile)){ $lang = array(); @include(DOKU_PLUGIN.$plugin.$enlangfile); if ($conf['lang'] != 'en') @include(DOKU_PLUGIN.$plugin.$langfile); @@ -303,7 +303,7 @@ class admin_plugin_config extends DokuWiki_Admin_Plugin { // the same for the active template $tpl = $conf['template']; - if (@file_exists(tpl_incdir().$enlangfile)){ + if (file_exists(tpl_incdir().$enlangfile)){ $lang = array(); @include(tpl_incdir().$enlangfile); if ($conf['lang'] != 'en') @include(tpl_incdir().$langfile); diff --git a/lib/plugins/config/settings/config.class.php b/lib/plugins/config/settings/config.class.php index 590631dae..316cc2c59 100644 --- a/lib/plugins/config/settings/config.class.php +++ b/lib/plugins/config/settings/config.class.php @@ -40,7 +40,7 @@ if (!class_exists('configuration')) { public function configuration($datafile) { global $conf, $config_cascade; - if (!@file_exists($datafile)) { + if (!file_exists($datafile)) { msg('No configuration metadata found at - '.htmlspecialchars($datafile),-1); return; } @@ -125,8 +125,8 @@ if (!class_exists('configuration')) { $file = end($this->_local_files); // backup current file (remove any existing backup) - if (@file_exists($file) && $backup) { - if (@file_exists($file.'.bak')) @unlink($file.'.bak'); + if (file_exists($file) && $backup) { + if (file_exists($file.'.bak')) @unlink($file.'.bak'); if (!io_rename($file, $file.'.bak')) return false; } @@ -191,7 +191,7 @@ if (!class_exists('configuration')) { if ($this->_format == 'php') { - if(@file_exists($file)){ + if(file_exists($file)){ $contents = @php_strip_whitespace($file); }else{ $contents = ''; @@ -281,7 +281,7 @@ if (!class_exists('configuration')) { $local = $this->_local_files[0]; if (!is_writable(dirname($local))) return true; - if (@file_exists($local) && !is_writable($local)) return true; + if (file_exists($local) && !is_writable($local)) return true; return false; } @@ -345,7 +345,7 @@ if (!class_exists('configuration')) { foreach ($this->get_plugin_list() as $plugin) { $plugin_dir = plugin_directory($plugin); - if (@file_exists(DOKU_PLUGIN.$plugin_dir.$file)){ + if (file_exists(DOKU_PLUGIN.$plugin_dir.$file)){ $meta = array(); @include(DOKU_PLUGIN.$plugin_dir.$file); @include(DOKU_PLUGIN.$plugin_dir.$class); @@ -360,7 +360,7 @@ if (!class_exists('configuration')) { } // the same for the active template - if (@file_exists(tpl_incdir().$file)){ + if (file_exists(tpl_incdir().$file)){ $meta = array(); @include(tpl_incdir().$file); @include(tpl_incdir().$class); @@ -388,7 +388,7 @@ if (!class_exists('configuration')) { foreach ($this->get_plugin_list() as $plugin) { $plugin_dir = plugin_directory($plugin); - if (@file_exists(DOKU_PLUGIN.$plugin_dir.$file)){ + if (file_exists(DOKU_PLUGIN.$plugin_dir.$file)){ $conf = $this->_read_config(DOKU_PLUGIN.$plugin_dir.$file); foreach ($conf as $key => $value){ $default['plugin'.CM_KEYMARKER.$plugin.CM_KEYMARKER.$key] = $value; @@ -397,7 +397,7 @@ if (!class_exists('configuration')) { } // the same for the active template - if (@file_exists(tpl_incdir().$file)){ + if (file_exists(tpl_incdir().$file)){ $conf = $this->_read_config(tpl_incdir().$file); foreach ($conf as $key => $value){ $default['tpl'.CM_KEYMARKER.$tpl.CM_KEYMARKER.$key] = $value; @@ -487,7 +487,7 @@ if (!class_exists('setting')) { * * @param DokuWiki_Plugin $plugin object of config plugin * @param bool $echo true: show inputted value, when error occurred, otherwise the stored setting - * @return array with content array(string $label_html, string $input_html) + * @return string[] with content array(string $label_html, string $input_html) */ public function html(&$plugin, $echo=false) { $disable = ''; @@ -712,7 +712,7 @@ if (!class_exists('setting_array')) { * * @param DokuWiki_Plugin $plugin object of config plugin * @param bool $echo true: show inputted value, when error occurred, otherwise the stored setting - * @return array with content array(string $label_html, string $input_html) + * @return string[] with content array(string $label_html, string $input_html) */ function html(&$plugin, $echo=false) { $disable = ''; @@ -748,7 +748,7 @@ if (!class_exists('setting_string')) { * * @param DokuWiki_Plugin $plugin object of config plugin * @param bool $echo true: show inputted value, when error occurred, otherwise the stored setting - * @return array with content array(string $label_html, string $input_html) + * @return string[] with content array(string $label_html, string $input_html) */ function html(&$plugin, $echo=false) { $disable = ''; @@ -809,7 +809,7 @@ if (!class_exists('setting_password')) { * * @param DokuWiki_Plugin $plugin object of config plugin * @param bool $echo true: show inputted value, when error occurred, otherwise the stored setting - * @return array with content array(string $label_html, string $input_html) + * @return string[] with content array(string $label_html, string $input_html) */ function html(&$plugin, $echo=false) { @@ -990,7 +990,7 @@ if (!class_exists('setting_onoff')) { * * @param DokuWiki_Plugin $plugin object of config plugin * @param bool $echo true: show inputted value, when error occurred, otherwise the stored setting - * @return array with content array(string $label_html, string $input_html) + * @return string[] with content array(string $label_html, string $input_html) */ function html(&$plugin, $echo = false) { $disable = ''; @@ -1044,7 +1044,7 @@ if (!class_exists('setting_multichoice')) { * * @param DokuWiki_Plugin $plugin object of config plugin * @param bool $echo true: show inputted value, when error occurred, otherwise the stored setting - * @return array with content array(string $label_html, string $input_html) + * @return string[] with content array(string $label_html, string $input_html) */ function html(&$plugin, $echo = false) { $disable = ''; @@ -1243,7 +1243,7 @@ if (!class_exists('setting_multicheckbox')) { * * @param DokuWiki_Plugin $plugin object of config plugin * @param bool $echo true: show inputted value, when error occurred, otherwise the stored setting - * @return array with content array(string $label_html, string $input_html) + * @return string[] with content array(string $label_html, string $input_html) */ function html(&$plugin, $echo=false) { diff --git a/lib/plugins/config/settings/extra.class.php b/lib/plugins/config/settings/extra.class.php index 232a8177f..fd3a90e28 100644 --- a/lib/plugins/config/settings/extra.class.php +++ b/lib/plugins/config/settings/extra.class.php @@ -151,7 +151,7 @@ if (!class_exists('setting_im_convert')) { $value = is_null($this->_local) ? $this->_default : $this->_local; if ($value == $input) return false; - if ($input && !@file_exists($input)) { + if ($input && !file_exists($input)) { $this->_error = true; $this->_input = $input; return false; |