Skip to content

Commit

Permalink
Merge pull request #539 from FriendsOfSymfony/cs
Browse files Browse the repository at this point in the history
fix cs and prepare release
  • Loading branch information
dbu committed Nov 2, 2022
2 parents 6b4b8f2 + c1e09e3 commit ec878d6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Expand Up @@ -3,6 +3,11 @@ Changelog

See also the [GitHub releases page](https://github.com/FriendsOfSymfony/FOSHttpCache/releases).

2.14.2
------

* Fixed varnish configuration examples to say `Authorization` and not `Autorization`.

2.14.1
------

Expand Down
9 changes: 3 additions & 6 deletions src/SymfonyCache/CacheInvalidation.php
Expand Up @@ -11,9 +11,6 @@

namespace FOS\HttpCache\SymfonyCache;

use function class_alias;
use function class_exists;

use Symfony\Component\HttpKernel\HttpKernelInterface;
use Symfony\Component\HttpKernel\Kernel;

Expand All @@ -25,15 +22,15 @@
* Symfony 6 introduced a BC break in the signature of the protected method HttpKernelInterface::fetch.
* Load the correct interface to match the signature.
*/
if (class_exists(Kernel::class) && Kernel::MAJOR_VERSION >= 6) {
if (\class_exists(Kernel::class) && Kernel::MAJOR_VERSION >= 6) {
// Load class for Symfony >=6.0
class_alias(
\class_alias(
Compatibility\CacheInvalidationS6::class,
CacheInvalidation::class
);
} else {
// Load class for any other cases
class_alias(
\class_alias(
Compatibility\CacheInvalidationLegacy::class,
CacheInvalidation::class
);
Expand Down

0 comments on commit ec878d6

Please sign in to comment.