bug #30050 [Cache] fix pruning pdo cache for vendors that throw on execute (bendavies)
This PR was merged into the 4.2 branch. Discussion ---------- [Cache] fix pruning pdo cache for vendors that throw on execute | Q | A | ------------- | --- | Branch? | 4.2 | Bug fix? | yes | New feature? | no | BC breaks? | no > | Deprecations? | no | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | This additionally fixes pruning of the PdoAdapter when the table does not exist. Similar to https://github.com/symfony/symfony/pull/29900 https://github.com/symfony/symfony/pull/30005 andf419851eb1
Commits -------14b9fa5234
fix pruning pdo cache for vendors that throw on execute
This commit is contained in:
commit
4e4ebdece2
@ -165,8 +165,11 @@ trait PdoTrait
|
|||||||
if ('' !== $this->namespace) {
|
if ('' !== $this->namespace) {
|
||||||
$delete->bindValue(':namespace', sprintf('%s%%', $this->namespace), \PDO::PARAM_STR);
|
$delete->bindValue(':namespace', sprintf('%s%%', $this->namespace), \PDO::PARAM_STR);
|
||||||
}
|
}
|
||||||
|
try {
|
||||||
return $delete->execute();
|
return $delete->execute();
|
||||||
|
} catch (TableNotFoundException $e) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Reference in New Issue
Block a user