Skip to content
This repository was archived by the owner on Sep 16, 2021. It is now read-only.

Commit 94f0b17

Browse files
committed
Fixes after david's comments
1 parent de422c4 commit 94f0b17

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

book/routing.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -498,9 +498,10 @@ also ``/projects`` as there is a default for the id parameter.
498498

499499
As you can see, the code explicitely creates the ``/cms/routes`` path.
500500
The RoutingBundle only creates this path automatically if the Sonata Admin
501-
was enabled in the routign configuration. Otherwise, it'll assume you
502-
do something yourself to create the path (by configuring an initializer
503-
or doing it in a fixture like this).
501+
was enabled in the routing configuration using an :ref:`initializer
502+
<phpcr-odm-repository-initializers>`. Otherwise, it'll assume you do
503+
something yourself to create the path (by configuring an initializer or
504+
doing it in a fixture like this).
504505

505506
Because you defined the ``{id}`` route parameter, your controller can expect an
506507
``$id`` parameter. Additionally, because you called setRouteContent on the

bundles/routing/configuration.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -443,9 +443,10 @@ initializer when you create your nodes your self (e.g. using Alice_).
443443

444444
.. caution::
445445

446-
The initializer is only run when the sonata admin is enabled. When you
447-
don't enable the sonata admin, it is assumed that you created an initializer
448-
yourself.
446+
Initializers are forced to be disabled when Sonata Admin is not enabled.
447+
In such cases, you might have multiple route basepaths which are created
448+
by other sources. If the route basepath isn't created by another source,
449+
you have to configure an :ref:`initializer <phpcr-odm-repository-initializers>`.
449450

450451
orm
451452
"""

0 commit comments

Comments
 (0)