public function setConfFilePath($v) { if (kString::beginsWith($v, "..")) { $err = "Error in " . __METHOD__ . ": attmpting to set ConfFilePath to [{$v}]"; KalturaLog::log($err); throw new APIException(APIErrors::ERROR_SETTING_FILE_PATH_FOR_UI_CONF, $v); } if ($this->getCreationMode() == self::UI_CONF_CREATION_MODE_MANUAL) { if (!kString::beginsWith($v, $this->getUiConfRootDirectory() . "uiconf/")) { $v = $this->getUiConfRootDirectory() . "uiconf/" . $v; } $real_v = realpath(dirname($v)) . "/" . pathinfo($v, PATHINFO_BASENAME); if ($v) { if ($real_v) { /* * TODO - add this id the service IS externally use via the API // the file exists - make sure we're not overiding someone elses file $ui_confs_with_same_path = uiConfPeer::retrieveByConfFilePath ( $real_v , $this->getId() ); foreach ( $ui_confs_with_same_path as $ui_conf ) { if ( $ui_conf->getPartnerId ( ) != $this->getPartnerId() ) { $err = "Error in " . __METHOD__ . ": attmpting to set ConfFilePath to [$v]"; KalturaLog::log( $err ); throw new APIException ( APIErrors::ERROR_SETTING_FILE_PATH_FOR_UI_CONF , $v ); } } */ $v = $real_v; } } parent::setConfFilePath($v); } else { parent::setConfFilePath($v); // throw new APIException ( APIErrors::ERROR_SETTING_FILE_PATH_FOR_UI_CONF , $v ); } }