@@ -28,11 +28,6 @@ class DumpCommand extends Command
2828{
2929 protected static $ defaultName = 'fos:js-routing:dump ' ;
3030
31- /**
32- * @var string
33- */
34- private $ targetPath ;
35-
3631 /**
3732 * @var ExposedRoutesExtractorInterface
3833 */
@@ -46,18 +41,18 @@ class DumpCommand extends Command
4641 /**
4742 * @var string
4843 */
49- private $ rootDir ;
44+ private $ projectDir ;
5045
5146 /**
5247 * @var string
5348 */
5449 private $ requestContextBaseUrl ;
5550
56- public function __construct (ExposedRoutesExtractorInterface $ extractor , SerializerInterface $ serializer , $ rootDir , $ requestContextBaseUrl = null )
51+ public function __construct (ExposedRoutesExtractorInterface $ extractor , SerializerInterface $ serializer , $ projectDir , $ requestContextBaseUrl = null )
5752 {
5853 $ this ->extractor = $ extractor ;
5954 $ this ->serializer = $ serializer ;
60- $ this ->rootDir = $ rootDir ;
55+ $ this ->projectDir = $ projectDir ;
6156 $ this ->requestContextBaseUrl = $ requestContextBaseUrl ;
6257
6358 parent ::__construct ();
@@ -145,8 +140,8 @@ private function doDump(InputInterface $input, OutputInterface $output)
145140 $ serializer = $ this ->serializer ;
146141 $ targetPath = $ input ->getOption ('target ' ) ?:
147142 sprintf (
148- '%s/../ web/js/fos_js_routes%s.%s ' ,
149- $ this ->rootDir ,
143+ '%s/web/js/fos_js_routes%s.%s ' ,
144+ $ this ->projectDir ,
150145 empty ($ domain ) ? '' : ('_ ' . implode ('_ ' , $ domain )),
151146 $ input ->getOption ('format ' )
152147 );
0 commit comments