-
Notifications
You must be signed in to change notification settings - Fork 65
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
Injection definition required for non-concrete parameter $interface of type Http\Request #85
Comments
Could you provide the relevant constructor / method signatures of the objects you're attempting to create, and explain what you're trying to do? |
Yes, a simple reproduce script would go a long way to diagnosing any potential issue. It would be very helpful if you could provide one :) |
I use it like this: use Http\Request; class Foo
} |
That is how I use it, and it generates that error when the class is instantiated. |
This problem is fixed when I use an old version of Auryn, so that is what I'm using right now. |
@HassanAlthaf And which version are you using right now? |
@HassanAlthaf Try this use \Http\Request;
use \Http\Response; |
I can't diagnose anything from the code samples provided. Please add a code snippet demonstrating actual Auryn usage that gives an error where a different result is expected. |
Closing as there's been no activity and no reproduce code ... |
Hey, I get that error when I had this code:
$injector->alias('Http\Response', 'Http\HttpResponse');
$injector->share('Http\HttpRequest');
$injector->define('Http\HttpRequest', [
':get' => $_GET,
':post' => $_POST,
':cookies' => $_COOKIE,
':files' => $_FILES,
':server' => $_SERVER,
]);
$injector->alias('Http\Request', 'Http\HttpRequest');
$injector->share('Http\HttpResponse');
However, when I use an old version of Auryn, it works perfectly fine! I bet this is a bug.
The text was updated successfully, but these errors were encountered: