@@ -94,10 +94,10 @@ implementation. Following the same example as before, the first change would be
9494to remove the ``priceFilter() `` method from the extension and update the PHP
9595callable defined in ``getFilters() ``::
9696
97- // src/AppBundle/ Twig/AppExtension.php
98- namespace AppBundle \Twig;
97+ // src/Twig/AppExtension.php
98+ namespace App \Twig;
9999
100- use AppBundle \Twig\AppRuntime;
100+ use App \Twig\AppRuntime;
101101
102102 class AppExtension extends \Twig_Extension
103103 {
@@ -114,8 +114,8 @@ Then, create the new ``AppRuntime`` class (it's not required but these classes
114114are suffixed with ``Runtime `` by convention) and include the logic of the
115115previous ``priceFilter() `` method::
116116
117- // src/AppBundle/ Twig/AppRuntime.php
118- namespace AppBundle \Twig;
117+ // src/Twig/AppRuntime.php
118+ namespace App \Twig;
119119
120120 class AppRuntime
121121 {
@@ -147,7 +147,7 @@ Finally, register your new class as a service and tag it with ``twig.runtime``
147147 # app/config/services.yml
148148 services :
149149 app.twig_runtime :
150- class : AppBundle \Twig\AppRuntime
150+ class : App \Twig\AppRuntime
151151 public : false
152152 tags :
153153 - { name: twig.runtime }
@@ -163,7 +163,7 @@ Finally, register your new class as a service and tag it with ``twig.runtime``
163163
164164 <services >
165165 <service id =" app.twig_runtime"
166- class =" AppBundle \Twig\AppRuntime"
166+ class =" App \Twig\AppRuntime"
167167 public =" false" >
168168 <tag name =" twig.runtime" />
169169 </service >
@@ -173,7 +173,7 @@ Finally, register your new class as a service and tag it with ``twig.runtime``
173173 .. code-block :: php
174174
175175 // app/config/services.php
176- use AppBundle \Twig\AppExtension;
176+ use App \Twig\AppExtension;
177177
178178 $container
179179 ->register('app.twig_runtime', AppRuntime::class)
0 commit comments