[5.8] added $params argument to resolve helper - #28020
Conversation
|
Can't we just add the |
|
Btw, you can already do this with $api = app('HelpSpot\API', ['id' => 1]); |
|
Hmm, Thanks. |
Should it be like that? |
resolveWith helper$params argument to resolve helper
|
@36864 |
|
Sorry, jumped the gun with my previous comment. I still think this type of alias helpers should just be removed, but no harm in just making it closer to the helper it's aliasing I guess. |
|
A little history: We’ve made it 2 years without anyone asking why. |
$api = resolve('HelpSpot\API');is an alias for$api = $this->app->make('HelpSpot\API');So, may
$api = resolveWith('HelpSpot\API', ['id' => 1]);be an alias for
$api = $this->app->makeWith('HelpSpot\API', ['id' => 1]);