mirror of
https://github.com/php-win-ext/phpredis.git
synced 2026-03-24 00:52:16 +01:00
Fix deprecated string format for php 8.2
PHP 8.2 deprecates "${var}" in favor of "{$var}"
This commit is contained in:
@@ -284,7 +284,7 @@ class Redis_Cluster_Test extends Redis_Test {
|
||||
|
||||
/* We should now have both prefixs' keys */
|
||||
foreach ($arr_keys as $str_prefix => $str_id) {
|
||||
$this->assertTrue(in_array("${str_prefix}${str_id}", $arr_scan_keys));
|
||||
$this->assertTrue(in_array("{$str_prefix}{$str_id}", $arr_scan_keys));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5484,7 +5484,7 @@ class Redis_Test extends TestSuite
|
||||
foreach ($arr_prefixes as $str_prefix) {
|
||||
$this->redis->setOption(Redis::OPT_PREFIX, $str_prefix);
|
||||
$this->redis->set("$keyid", "LOLWUT");
|
||||
$arr_all_keys["${str_prefix}${keyid}"] = true;
|
||||
$arr_all_keys["{$str_prefix}{$keyid}"] = true;
|
||||
}
|
||||
|
||||
$this->redis->setOption(Redis::OPT_SCAN, Redis::SCAN_RETRY);
|
||||
@@ -5494,7 +5494,7 @@ class Redis_Test extends TestSuite
|
||||
$this->redis->setOption(Redis::OPT_PREFIX, $str_prefix);
|
||||
$it = NULL;
|
||||
$arr_keys = $this->redis->scan($it, "*$keyid*");
|
||||
$this->assertEquals($arr_keys, ["${str_prefix}${keyid}"]);
|
||||
$this->assertEquals($arr_keys, ["{$str_prefix}{$keyid}"]);
|
||||
}
|
||||
|
||||
/* Unset the prefix option */
|
||||
|
||||
Reference in New Issue
Block a user