Skip to content

Commit 3f1a810

Browse files
committed
Merge branch '4.1'
* 4.1: added a space before "=" in code fix the markup Changing to absolute url, as requested Updated link to Event Listeners page Update form_customization.rst Revert "Fix typo on which YAML values must not be quoted" Fix typo (shard -> shared) Fix typo on which YAML values must not be quoted Change all occurrences of Controller to AbstractController fix `HandlerLocator`'s use statement
2 parents 7bfbf58 + ddb7572 commit 3f1a810

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+100
-100
lines changed

best_practices/forms.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,10 +104,10 @@ some developers configure form buttons in the controller::
104104
use App\Entity\Post;
105105
use App\Form\PostType;
106106
use Symfony\Component\HttpFoundation\Request;
107-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
107+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
108108
use Symfony\Component\Form\Extension\Core\Type\SubmitType;
109109

110-
class PostController extends Controller
110+
class PostController extends AbstractController
111111
{
112112
// ...
113113

components/form.rst

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -406,12 +406,12 @@ is created from the form factory.
406406
// src/Controller/TaskController.php
407407
namespace App\Controller;
408408
409-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
409+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
410410
use Symfony\Component\HttpFoundation\Request;
411411
use Symfony\Component\Form\Extension\Core\Type\TextType;
412412
use Symfony\Component\Form\Extension\Core\Type\DateType;
413413
414-
class TaskController extends Controller
414+
class TaskController extends AbstractController
415415
{
416416
public function new(Request $request)
417417
{
@@ -468,11 +468,11 @@ builder:
468468
// src/Controller/DefaultController.php
469469
namespace App\Controller;
470470
471-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
471+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
472472
use Symfony\Component\Form\Extension\Core\Type\TextType;
473473
use Symfony\Component\Form\Extension\Core\Type\DateType;
474474
475-
class DefaultController extends Controller
475+
class DefaultController extends AbstractController
476476
{
477477
public function new(Request $request)
478478
{
@@ -550,10 +550,10 @@ by ``handleRequest()`` to determine whether a form has been submitted):
550550
// src/Controller/DefaultController.php
551551
namespace App\Controller;
552552
553-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
553+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
554554
use Symfony\Component\Form\Extension\Core\Type\FormType;
555555
556-
class DefaultController extends Controller
556+
class DefaultController extends AbstractController
557557
{
558558
public function search()
559559
{
@@ -612,11 +612,11 @@ method:
612612
// src/Controller/TaskController.php
613613
namespace App\Controller;
614614
615-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
615+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
616616
use Symfony\Component\Form\Extension\Core\Type\DateType;
617617
use Symfony\Component\Form\Extension\Core\Type\TextType;
618618
619-
class TaskController extends Controller
619+
class TaskController extends AbstractController
620620
{
621621
public function new(Request $request)
622622
{
@@ -688,13 +688,13 @@ option when building each field:
688688
// src/Controller/DefaultController.php
689689
namespace App\Controller;
690690
691-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
691+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
692692
use Symfony\Component\Validator\Constraints\NotBlank;
693693
use Symfony\Component\Validator\Constraints\Type;
694694
use Symfony\Component\Form\Extension\Core\Type\DateType;
695695
use Symfony\Component\Form\Extension\Core\Type\TextType;
696696
697-
class DefaultController extends Controller
697+
class DefaultController extends AbstractController
698698
{
699699
public function new(Request $request)
700700
{

components/lock.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ then the lock is considered as acquired; otherwise as not acquired::
262262

263263
$stores = [];
264264
foreach (array('server1', 'server2', 'server3') as $server) {
265-
$redis= new \Redis();
265+
$redis = new \Redis();
266266
$redis->connect($server);
267267

268268
$stores[] = new RedisStore($redis);

components/messenger.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ Example::
6161

6262
use App\Message\MyMessage;
6363
use Symfony\Component\Messenger\MessageBus;
64-
use Symfony\Component\Messenger\HandlerLocator;
64+
use Symfony\Component\Messenger\Handler\Locator\HandlerLocator;
6565
use Symfony\Component\Messenger\Middleware\HandleMessageMiddleware;
6666

6767
$bus = new MessageBus([

components/routing.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -393,10 +393,10 @@ routes with UTF-8 characters:
393393
394394
namespace App\Controller;
395395
396-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
396+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
397397
use Symfony\Component\Routing\Annotation\Route;
398398
399-
class DefaultController extends Controller
399+
class DefaultController extends AbstractController
400400
{
401401
/**
402402
* @Route("/category/{name}", name="route1", options={"utf8": true})
@@ -462,10 +462,10 @@ You can also include UTF-8 strings as routing requirements:
462462
463463
namespace App\Controller;
464464
465-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
465+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
466466
use Symfony\Component\Routing\Annotation\Route;
467467
468-
class DefaultController extends Controller
468+
class DefaultController extends AbstractController
469469
{
470470
/**
471471
* @Route(

configuration/micro_kernel_trait.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -249,10 +249,10 @@ has one file in it::
249249
// src/Controller/MicroController.php
250250
namespace App\Controller;
251251

252-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
252+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
253253
use Symfony\Component\Routing\Annotation\Route;
254254

255-
class MicroController extends Controller
255+
class MicroController extends AbstractController
256256
{
257257
/**
258258
* @Route("/random/{limit}")

console/command_in_controller.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ Run this command from inside your controller via::
2828
namespace App\Controller;
2929

3030
use Symfony\Bundle\FrameworkBundle\Console\Application;
31-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
31+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
3232
use Symfony\Component\Console\Input\ArrayInput;
3333
use Symfony\Component\Console\Output\BufferedOutput;
3434
use Symfony\Component\HttpFoundation\Response;
3535
use Symfony\Component\HttpKernel\KernelInterface;
3636

37-
class SpoolController extends Controller
37+
class SpoolController extends AbstractController
3838
{
3939
public function sendSpool($messages = 10, KernelInterface $kernel)
4040
{
@@ -85,7 +85,7 @@ Now, use it in your controller::
8585
use Symfony\Component\HttpFoundation\Response;
8686
// ...
8787

88-
class SpoolController extends Controller
88+
class SpoolController extends AbstractController
8989
{
9090
public function sendSpool($messages = 10)
9191
{

controller/soap_web_service.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,12 +59,12 @@ can be retrieved via ``/soap?wsdl``::
5959

6060
namespace App\Controller;
6161

62-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
62+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
6363
use Symfony\Component\HttpFoundation\Response;
6464
use Symfony\Component\Routing\Annotation\Route;
6565
use App\Service\HelloService;
6666

67-
class HelloServiceController extends Controller
67+
class HelloServiceController extends AbstractController
6868
{
6969
/**
7070
* @Route("/soap")

controller/upload_file.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,13 +99,13 @@ Finally, you need to update the code of the controller that handles the form::
9999
// src/Controller/ProductController.php
100100
namespace App\Controller;
101101

102-
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
102+
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
103103
use Symfony\Component\HttpFoundation\Request;
104104
use Symfony\Component\Routing\Annotation\Route;
105105
use App\Entity\Product;
106106
use App\Form\ProductType;
107107

108-
class ProductController extends Controller
108+
class ProductController extends AbstractController
109109
{
110110
/**
111111
* @Route("/product/new", name="app_product_new")

doctrine.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@ and save it!
336336
// ...
337337
use App\Entity\Product;
338338
339-
class ProductController extends Controller
339+
class ProductController extends AbstractController
340340
{
341341
/**
342342
* @Route("/product", name="product")

0 commit comments

Comments
 (0)