-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ADD] Methods Map::appendMap() and Map::prependMap(), to append or pr…
…epend the definitions from another map.
- Loading branch information
Paul M. Jones
committed
Oct 16, 2013
1 parent
dad01e1
commit 98afc57
Showing
2 changed files
with
72 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
98afc57
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it seems like we are using different Maps for different packages ?
98afc57
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No; the problem is that defining routes via the Map $di->params is more detailed than I'd like. The plan is to create a $router object (like we have $di, $system, and $config objects) and make it available to the config files. Then people can do $router->add('name', '/path/to/whatever') directly. The followup problem is that the $di->params for Map won't be honored, so the framework bootstrap creates a second router object to get the config definitions, and prepends them to the $router we already have. Yes, it's a hack, but it also makes things easier at the user end. /me wipes brow
98afc57
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.