Skip to content
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

Map::getFacadeAccessor() returning new instance with each call to Map facade #61

Closed
JFossey opened this issue Feb 8, 2017 · 1 comment

Comments

@JFossey
Copy link
Contributor

JFossey commented Feb 8, 2017

Thanks for a very helpful and time saving package.

I was trying to use a custom blueprint class by using Map::blueprintResolver(). This seemed to have no effect.

After a short investigation I discovered that because Map::getFacadeAccessor() is returning an object instance and Facades::resolveFacadeInstance($name) returns objects immediately without adding them to the $resolvedInstance static property.

The side effect to this that every call to the Map facade will resolve a new instance of Builder making the blueprintResolver() method un-usable.

So from my point of view if I understand everything correctly, to use the Map Facade as intended getFacadeAccessor() will need to return a object instance saved to a property in Connection or a Application container singleton.

@JFossey JFossey changed the title Sleimanx2\Plastic\Facades\Map::getFacadeAccessor() returning new instance with each call to Map facade Map::getFacadeAccessor() returning new instance with each call to Map facade Feb 8, 2017
@sleimanx2
Copy link
Owner

fix #62

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

No branches or pull requests

2 participants