Fix DatabaseCacheDriver::get SQL select
- Fix typo - Fix wrong usage of NOW()
This commit is contained in:
parent
41d5c7d4c7
commit
3df34d33d5
1 changed files with 1 additions and 1 deletions
|
@ -16,7 +16,7 @@ class DatabaseCacheDriver implements ICacheDriver
|
|||
{
|
||||
public function get($key)
|
||||
{
|
||||
$cache = dba::selectFirst('cache', ['v'], ['`k` = ? AND `expires` >= NOW()`', $key]);
|
||||
$cache = dba::selectFirst('cache', ['v'], ['`k` = ? AND `expires` >= ?', $key, DateTimeFormat::utcNow()]);
|
||||
|
||||
if (DBM::is_result($cache)) {
|
||||
$cached = $cache['v'];
|
||||
|
|
Loading…
Reference in a new issue