Merge pull request #16493 from nextcloud/enh/remove-curly-braces

The array and string offset access syntax using curly braces is depre…
This commit is contained in:
Roeland Jago Douma 2019-07-24 09:35:20 +02:00 committed by GitHub
commit 59d8c92b64
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -111,7 +111,7 @@ class Util {
public function hexToRGB($color) {
$hex = preg_replace("/[^0-9A-Fa-f]/", '', $color);
if (strlen($hex) === 3) {
$hex = $hex{0} . $hex{0} . $hex{1} . $hex{1} . $hex{2} . $hex{2};
$hex = $hex[0] . $hex[0] . $hex[1] . $hex[1] . $hex[2] . $hex[2];
}
if (strlen($hex) !== 6) {
return 0;