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

Intercepting execution of PHP system functions #173

Closed
mbiewenermos opened this issue Mar 4, 2021 · 1 comment
Closed

Intercepting execution of PHP system functions #173

mbiewenermos opened this issue Mar 4, 2021 · 1 comment

Comments

@mbiewenermos
Copy link

Is it possible to use this framework to modify system functions/methods? Specifically, I was hoping to be able to modify the date() function. Thank you!

@koriym
Copy link
Member

koriym commented Mar 5, 2021

Ray.Aop only supports "method" interception. Cannot be applied to functions.

By the way, instead of calling date, it would be better to inject the code as a dependency on the current time, such as "ClockInterface".

@koriym koriym closed this as completed Mar 5, 2021
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