1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-13 03:25:55 +00:00

Address PHPStan warnings in 'classes/sanitizer.php'.

This also includes some minor tweaks to things that call 'Sanitizer::sanitize()'.
This commit is contained in:
wn_
2021-11-11 19:59:25 +00:00
parent 3f8aaffd34
commit 03495c11ed
6 changed files with 28 additions and 13 deletions

View File

@@ -181,8 +181,14 @@
return Feeds::_get_counters($feed, $is_cat, true, $_SESSION["uid"]);
}
/** function is @deprecated by Sanitizer::sanitize() */
function sanitize($str, $force_remove_images = false, $owner = false, $site_url = false, $highlight_words = false, $article_id = false) {
/**
* @deprecated by Sanitizer::sanitize()
*
* @param array<int, string>|null $highlight_words Words to highlight in the HTML output.
*
* @return false|string The HTML, or false if an error occurred.
*/
function sanitize(string $str, bool $force_remove_images = false, int $owner = null, string $site_url = null, array $highlight_words = null, int $article_id = null) {
return Sanitizer::sanitize($str, $force_remove_images, $owner, $site_url, $highlight_words, $article_id);
}