File tree Expand file tree Collapse file tree 5 files changed +7
-25
lines changed Expand file tree Collapse file tree 5 files changed +7
-25
lines changed Original file line number Diff line number Diff line change @@ -77,11 +77,8 @@ so Symfony doesn't try to get/set its value from the related entity::
7777 'constraints' => [
7878 new File(
7979 maxSize: '1024k',
80- mimeTypes: [
81- 'application/pdf',
82- 'application/x-pdf',
83- ],
84- mimeTypesMessage: 'Please upload a valid PDF document',
80+ extensions: ['pdf'],
81+ extensionsMessage: 'Please upload a valid PDF document',
8582 )
8683 ],
8784 ])
Original file line number Diff line number Diff line change @@ -501,7 +501,7 @@ following method to the ``ProductRepository`` class::
501501 }
502502 }
503503
504- This will *still * return an array of ``Product `` objects . But now, when you call
504+ This will *still * return a ``Product `` object . But now, when you call
505505``$product->getCategory() `` and use that data, no second query is made.
506506
507507Now, you can use this method in your controller to query for a ``Product ``
Original file line number Diff line number Diff line change @@ -304,23 +304,6 @@ listener in the Symfony application by creating a new service for it and
304304
305305.. configuration-block ::
306306
307- .. code-block :: php-attributes
308-
309- // src/EventListener/SearchIndexer.php
310- namespace App\EventListener;
311-
312- use Doctrine\Bundle\DoctrineBundle\Attribute\AsDoctrineListener;
313- use Doctrine\ORM\Event\PostPersistEventArgs;
314-
315- #[AsDoctrineListener('postPersist'/*, 500, 'default'*/)]
316- class SearchIndexer
317- {
318- public function postPersist(PostPersistEventArgs $event): void
319- {
320- // ...
321- }
322- }
323-
324307 .. code-block :: yaml
325308
326309 # config/services.yaml
Original file line number Diff line number Diff line change @@ -1504,7 +1504,7 @@ RabbitMQ. Install it by running:
15041504
15051505 $ composer require symfony/amqp-messenger
15061506
1507- The AMQP transport DSN may looks like this:
1507+ The AMQP transport DSN may look like this:
15081508
15091509.. code-block :: env
15101510
Original file line number Diff line number Diff line change @@ -146,7 +146,8 @@ The WebLink component provides the following Twig functions to send those hints:
146146* ``prefetch() ``: "identifies a resource that might be required by the next
147147 navigation, and that the user agent *should * fetch, such that the user agent
148148 can deliver a faster response once the resource is requested in the future".
149- * ``prerender() ``: "identifies a resource that might be required by the next
149+ * ``prerender() ``: " **deprecated ** and superseded by the `Speculation Rules API `_,
150+ identifies a resource that might be required by the next
150151 navigation, and that the user agent *should * fetch and execute, such that the
151152 user agent can deliver a faster response once the resource is requested later".
152153
@@ -206,3 +207,4 @@ You can also add links to the HTTP response directly from controllers and servic
206207.. _`Akamai` : https://http2.akamai.com/
207208.. _`link defined in the HTML specification` : https://html.spec.whatwg.org/dev/links.html#linkTypes
208209.. _`PSR-13` : https://www.php-fig.org/psr/psr-13/
210+ .. _`Speculation Rules API` : https://developer.mozilla.org/docs/Web/API/Speculation_Rules_API
You can’t perform that action at this time.
0 commit comments