1<?php 2 3namespace dokuwiki\plugin\config\core\Setting; 4 5/** 6 * Class setting_im_convert 7 */ 8class SettingImConvert extends SettingString 9{ 10 11 /** @inheritdoc */ 12 public function update($input) 13 { 14 if($this->isProtected()) return false; 15 16 $input = trim($input); 17 18 $value = is_null($this->local) ? $this->default : $this->local; 19 if($value == $input) return false; 20 21 if($input && !file_exists($input)) { 22 $this->error = true; 23 $this->input = $input; 24 return false; 25 } 26 27 $this->local = $input; 28 return true; 29 } 30} 31