Skip to content

Commit 4acbaba

Browse files
author
Leandre
authored
Merge pull request #52 from nly/master
排除同步redis增加EX
2 parents 1e5d54c + 27dc5c0 commit 4acbaba

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Pools/CoroutineRedisProxy.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ public function __call(string $name, array $arguments)
200200
switch (strtolower($name)) {
201201
case 'set':
202202
$arguments[2] = $this->serializeHandler($arguments[2], true);
203-
if (isset($arguments[3]) && is_int($arguments[3])) {
203+
if (isset($arguments[3]) && is_int($arguments[3]) && getInstance()->processType == Marco::PROCESS_WORKER) {
204204
//当设置了过期时间时,需要追加EX前缀 SET key value [EX seconds]
205205
array_splice($arguments, 3, 0, 'EX');
206206
}

0 commit comments

Comments
 (0)