Merge pull request #1411 from icambridge/patch-1
Allow null to be passed to setHydrationCacheProfile
This commit is contained in:
commit
6423a33a23
@ -502,7 +502,7 @@ abstract class AbstractQuery
|
|||||||
*/
|
*/
|
||||||
public function setHydrationCacheProfile(QueryCacheProfile $profile = null)
|
public function setHydrationCacheProfile(QueryCacheProfile $profile = null)
|
||||||
{
|
{
|
||||||
if ( ! $profile->getResultCacheDriver()) {
|
if ($profile !== null && ! $profile->getResultCacheDriver()) {
|
||||||
$resultCacheDriver = $this->_em->getConfiguration()->getHydrationCacheImpl();
|
$resultCacheDriver = $this->_em->getConfiguration()->getHydrationCacheImpl();
|
||||||
$profile = $profile->setResultCacheDriver($resultCacheDriver);
|
$profile = $profile->setResultCacheDriver($resultCacheDriver);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user