@@ -258,10 +258,10 @@ public function exists(Key $key)
258
258
private function evaluate (string $ script , string $ resource , array $ args )
259
259
{
260
260
if (
261
- $ this ->redis instanceof \Redis ||
262
- $ this ->redis instanceof \RedisCluster ||
263
- $ this ->redis instanceof RedisProxy ||
264
- $ this ->redis instanceof RedisClusterProxy
261
+ $ this ->redis instanceof \Redis
262
+ || $ this ->redis instanceof \RedisCluster
263
+ || $ this ->redis instanceof RedisProxy
264
+ || $ this ->redis instanceof RedisClusterProxy
265
265
) {
266
266
$ this ->redis ->clearLastError ();
267
267
$ result = $ this ->redis ->eval ($ script , array_merge ([$ resource ], $ args ), 1 );
@@ -317,7 +317,9 @@ private function getNowCode(): string
317
317
try {
318
318
$ this ->supportTime = 1 === $ this ->evaluate ($ script , 'symfony_check_support_time ' , []);
319
319
} catch (LockStorageException $ e ) {
320
- if (false === strpos ($ e ->getMessage (), 'commands not allowed after non deterministic ' )) {
320
+ if (!str_contains ($ e ->getMessage (), 'commands not allowed after non deterministic ' )
321
+ && !str_contains ($ e ->getMessage (), 'is not allowed from script script ' )
322
+ ) {
321
323
throw $ e ;
322
324
}
323
325
$ this ->supportTime = false ;
0 commit comments