diff options
author | John Molakvoæ <skjnldsv@users.noreply.github.com> | 2022-01-27 20:04:02 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-27 20:04:02 +0100 |
commit | 73e3d06781d0b0f5f38a30ff6365fe79c9421caa (patch) | |
tree | 66ba1a25e3e4907aa85041727b01f9666db179ea /lib/private | |
parent | 3231b3f49f1c5db58b50079c155adc2921099738 (diff) | |
parent | 760db78dbac8ac81f58dd0f2797b7d76fb0af239 (diff) | |
download | nextcloud-server-73e3d06781d0b0f5f38a30ff6365fe79c9421caa.tar.gz nextcloud-server-73e3d06781d0b0f5f38a30ff6365fe79c9421caa.zip |
Merge pull request #30855 from nextcloud/psalm/theming
Diffstat (limited to 'lib/private')
-rw-r--r-- | lib/private/Memcache/Memcached.php | 9 | ||||
-rw-r--r-- | lib/private/legacy/OC_Util.php | 5 |
2 files changed, 10 insertions, 4 deletions
diff --git a/lib/private/Memcache/Memcached.php b/lib/private/Memcache/Memcached.php index 08880451a73..f78be581d63 100644 --- a/lib/private/Memcache/Memcached.php +++ b/lib/private/Memcache/Memcached.php @@ -65,8 +65,13 @@ class Memcached extends Cache implements IMemcache { // Enable Binary Protocol //\Memcached::OPT_BINARY_PROTOCOL => true, ]; - // by default enable igbinary serializer if available - /** @psalm-suppress RedundantCondition */ + /** + * By default enable igbinary serializer if available + * + * Psalm checks depend on if igbinary is installed or not with memcached + * @psalm-suppress RedundantCondition + * @psalm-suppress TypeDoesNotContainType + */ if (\Memcached::HAVE_IGBINARY) { $defaultOptions[\Memcached::OPT_SERIALIZER] = \Memcached::SERIALIZER_IGBINARY; diff --git a/lib/private/legacy/OC_Util.php b/lib/private/legacy/OC_Util.php index 4b53bbca3fc..abe7e59f695 100644 --- a/lib/private/legacy/OC_Util.php +++ b/lib/private/legacy/OC_Util.php @@ -1130,11 +1130,12 @@ class OC_Util { * This function is used to sanitize HTML and should be applied on any * string or array of strings before displaying it on a web page. * - * @param string|array $value - * @return string|array an array of sanitized strings or a single sanitized string, depends on the input parameter. + * @param string|string[] $value + * @return string|string[] an array of sanitized strings or a single sanitized string, depends on the input parameter. */ public static function sanitizeHTML($value) { if (is_array($value)) { + /** @var string[] $value */ $value = array_map(function ($value) { return self::sanitizeHTML($value); }, $value); |