Add key expiration support in Redis class with expire method implementation

This commit is contained in:
Jepp9350
2025-06-03 10:16:58 +02:00
parent b0173193f2
commit ff4c18a45d
+6
View File
@@ -379,5 +379,11 @@ class redis implements redis_i
return $this;
}
public function expire(string $key, int $seconds): self
{
// Set the expiration time for a key
$this->redis->expire($key, $seconds);
return $this;
}
}