<?php
/**
- * @copyright Copyright (C) 2020, Friendica
+ * @copyright Copyright (C) 2010-2021, the Friendica project
*
* @license GNU AGPL version 3 or any later version
*
use Friendica\App;
use Friendica\BaseModule;
use Friendica\Core;
-use Friendica\Core\Config\Cache;
+use Friendica\Core\Config\ValueObject\Cache;
use Friendica\Core\Renderer;
use Friendica\Core\Theme;
use Friendica\DI;
use Friendica\Network\HTTPException;
use Friendica\Util\BasePath;
-use Friendica\Util\Strings;
use Friendica\Util\Temporal;
class Install extends BaseModule
/**
* Checks the $_POST settings and updates the config Cache for it
*
- * @param Cache $configCache The current config cache
- * @param array $post The $_POST data
- * @param string $cat The category of the setting
- * @param string $key The key of the setting
- * @param null|string $default The default value
+ * @param \Friendica\Core\Config\ValueObject\Cache $configCache The current config cache
+ * @param array $post The $_POST data
+ * @param string $cat The category of the setting
+ * @param string $key The key of the setting
+ * @param null|string $default The default value
*/
private static function checkSetting(Cache $configCache, array $post, $cat, $key, $default = null)
{
$configCache->set($cat, $key,
- Strings::escapeTags(
- trim(($post[sprintf('%s-%s', $cat, $key)] ?? '') ?:
- ($default ?? $configCache->get($cat, $key))
- )
+ trim(($post[sprintf('%s-%s', $cat, $key)] ?? '') ?:
+ ($default ?? $configCache->get($cat, $key))
)
);
}