Skip to content

Commit 2815a67

Browse files
committed
minor #12691 [Validator] add deprecation log to class ApcCache (#12665) (kbsali)
This PR was merged into the 2.7 branch. Discussion ---------- [Validator] add deprecation log to class ApcCache (#12665) | Q | A | ------------- | --- | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | yes | Tests pass? | yes | Fixed tickets | #12665 | License | MIT | Doc PR | This adds depreciation note for the Symfony\Component\Validator\Mapping\Cache\ApcCache class. Commits ------- 881ed1e [Validator] add deprecation log (#12665)
2 parents dfbddc4 + 78085bb commit 2815a67

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Mapping/Cache/ApcCache.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ class ApcCache implements CacheInterface
2323

2424
public function __construct($prefix)
2525
{
26+
trigger_error('The Symfony\Component\Validator\Mapping\Cache\ApcCache class is deprecated since version 2.5 and will be removed in 3.0. Use DoctrineCache with Doctrine\Common\Cache\ApcCache instead.', E_USER_DEPRECATED);
27+
2628
if (!extension_loaded('apc')) {
2729
throw new \RuntimeException('Unable to use ApcCache to cache validator mappings as APC is not enabled.');
2830
}

0 commit comments

Comments
 (0)