From bfbef39b1f07dc5cdfeb7dba4843ee086ca0c065 Mon Sep 17 00:00:00 2001 From: David Grudl Date: Wed, 3 Mar 2021 22:17:38 +0100 Subject: [PATCH] fixed compatibility with Symfony DebugClassLoader --- src/compatibility.php | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/compatibility.php b/src/compatibility.php index 6f9061253..84d758ef9 100644 --- a/src/compatibility.php +++ b/src/compatibility.php @@ -14,18 +14,24 @@ class IControl extends Control { } +} elseif (!interface_exists(IControl::class)) { + class_alias(Control::class, IControl::class); +} +if (false) { /** @deprecated use Nette\Forms\FormRenderer */ class IFormRenderer extends FormRenderer { } +} elseif (!interface_exists(IFormRenderer::class)) { + class_alias(FormRenderer::class, IFormRenderer::class); +} +if (false) { /** @deprecated use Nette\Forms\SubmitterControl */ class ISubmitterControl extends SubmitterControl { } -} elseif (!interface_exists(IControl::class)) { - class_alias(Control::class, IControl::class); - class_alias(FormRenderer::class, IFormRenderer::class); +} elseif (!interface_exists(ISubmitterControl::class)) { class_alias(SubmitterControl::class, ISubmitterControl::class); }