1818 */
1919class SubresourceIntegrityRepository
2020{
21- /**
22- * Cache prefix.
23- *
24- * @var string
25- */
26- private const CACHE_PREFIX = 'INTEGRITY ' ;
2721
2822 /**
2923 * @var array|null
@@ -35,11 +29,6 @@ class SubresourceIntegrityRepository
3529 */
3630 private ?string $ context ;
3731
38- /**
39- * @var CacheInterface
40- */
41- private CacheInterface $ cache ;
42-
4332 /**
4433 * @var SerializerInterface
4534 */
@@ -53,20 +42,17 @@ class SubresourceIntegrityRepository
5342 private File $ sriStorage ;
5443
5544 /**
56- * @param CacheInterface $cache
5745 * @param SerializerInterface $serializer
5846 * @param SubresourceIntegrityFactory $integrityFactory
5947 * @param string|null $context
6048 * @param File|null $sriStorage
6149 */
6250 public function __construct (
63- CacheInterface $ cache ,
6451 SerializerInterface $ serializer ,
6552 SubresourceIntegrityFactory $ integrityFactory ,
6653 ?string $ context = null ,
6754 ? File $ sriStorage = null
6855 ) {
69- $ this ->cache = $ cache ;
7056 $ this ->serializer = $ serializer ;
7157 $ this ->integrityFactory = $ integrityFactory ;
7258 $ this ->context = $ context ;
@@ -196,21 +182,4 @@ private function getData(): array
196182
197183 return $ this ->data ;
198184 }
199-
200- /**
201- * Gets a cache key based on current context.
202- *
203- * @return string
204- * @deprecated Filesystem storage used instead of a cache
205- */
206- private function getCacheKey (): string
207- {
208- $ cacheKey = self ::CACHE_PREFIX ;
209-
210- if ($ this ->context ) {
211- $ cacheKey .= "_ " . $ this ->context ;
212- }
213-
214- return $ cacheKey ;
215- }
216185}
0 commit comments