diff options
| author | 2022-02-06 14:31:36 +0100 | |
|---|---|---|
| committer | 2022-02-06 14:31:36 +0100 | |
| commit | 1c5cf718599f698836fef3f8f88748757a7e85b5 (patch) | |
| tree | 2760e8a90bb653cb4000a4f236b1bfec4508e948 /lib | |
| parent | fe880d1a98d8224682036e44520bb92b2ed417aa (diff) | |
Fix Fever 32 bit ID issue + more PHP type hints (#4201)
* Fix Fever 32 bit ID issue + more PHP type hints
#fix https://github.com/FreshRSS/FreshRSS/issues/4200
Follow up and fix regression from https://github.com/FreshRSS/FreshRSS/pull/4110
* More PHP type hints with PHPStan
* Fix pull problem
* Avoid more nulls
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/lib_rss.php | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/lib/lib_rss.php b/lib/lib_rss.php index 5b335e8d8..b608743f3 100644 --- a/lib/lib_rss.php +++ b/lib/lib_rss.php @@ -193,11 +193,7 @@ function timestamptodate ($t, $hour = true) { return @date ($date, $t); } -/** - * @param string $text - * @return string - */ -function html_only_entity_decode($text) { +function html_only_entity_decode(string $text): string { static $htmlEntitiesOnly = null; if ($htmlEntitiesOnly === null) { $htmlEntitiesOnly = array_flip(array_diff( @@ -210,9 +206,8 @@ function html_only_entity_decode($text) { /** * @param array<string,mixed> $attributes - * @return SimplePie */ -function customSimplePie($attributes = array()) { +function customSimplePie($attributes = array()): SimplePie { $limits = FreshRSS_Context::$system_conf->limits; $simplePie = new SimplePie(); $simplePie->set_useragent(FRESHRSS_USERAGENT); |
