Skip to content

Routes should be just imported, not mounted #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 27, 2016
Merged

Routes should be just imported, not mounted #1

merged 1 commit into from
May 27, 2016

Conversation

OndraM
Copy link
Contributor

@OndraM OndraM commented May 25, 2016

Routes should be just imported, they don't need to be mounted.

Before (note doubled route prefixes):

(master) $ bin/console debug:router
 -------------------------- -------- -------- ------ --------------------------------------------- 
  Name                       Method   Scheme   Host   Path                                         
 -------------------------- -------- -------- ------ --------------------------------------------- 
  _wdt                       ANY      ANY      ANY    /_wdt/_wdt/{token}                           
  _profiler_home             ANY      ANY      ANY    /_profiler/_profiler/                        
  _profiler_search           ANY      ANY      ANY    /_profiler/_profiler/search                  
  _profiler_search_bar       ANY      ANY      ANY    /_profiler/_profiler/search_bar              
...                  
 -------------------------- -------- -------- ------ --------------------------------------------- 

After:

(import-routes) $ bin/console debug:router
 -------------------------- -------- -------- ------ ----------------------------------- 
  Name                       Method   Scheme   Host   Path                               
 -------------------------- -------- -------- ------ ----------------------------------- 
  _wdt                       ANY      ANY      ANY    /_wdt/{token}                      
  _profiler_home             ANY      ANY      ANY    /_profiler/                        
  _profiler_search           ANY      ANY      ANY    /_profiler/search                  
  _profiler_search_bar       ANY      ANY      ANY    /_profiler/search_bar              
...                       
 -------------------------- -------- -------- ------ -----------------------------------

The problem originated from the cookbook I guess: symfony/symfony-docs#6612

@ikoene
Copy link
Owner

ikoene commented May 27, 2016

I had no idea this behavior occurred. Good job 👍

@ikoene ikoene merged commit c7bf06b into ikoene:master May 27, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants