-
Notifications
You must be signed in to change notification settings - Fork 17
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
$event->getResult() allways null #16
Comments
Ok, from what I saw in Laminas MVC core code, a code update is required in BjyAuthorize\Guard\Route, replacing :
by :
In this case the event is not cloned |
hi @dsoriano, if you want you can do a PullRequet. On sunday i try to check it and fix the problem, hope thats okay for you. |
@kokspflanze This is done, unit tests have been updated too. |
thanks, i will test my parts next days and release a new version=] |
Thanks ! 👍 |
Hello,
I'm currently migrate a ZF2 app using BjyAuthorize and the Route Guard to Laminas.
In this app there is an API part that return JSON. In case of Unauthorized access, the app listener doesn't return a response but set a result to the dispatched event.
Actually if there is no response after trigger the error, the BjyAuthorize\Guard\Route check the event result :
The problem is in Laminas, trigger an event dispatch a clone of the eventPrototype :
So if in my listener I set a result to the event, it will be not set on the event of the BjyAuthorize\Guard\Route class but on the clone
Do you know how to deal with that ?
Thanks in advance
The text was updated successfully, but these errors were encountered: