-
Notifications
You must be signed in to change notification settings - Fork 81
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
Error: Cannot write property #28
Comments
@rowhel95 please provide a code snippet so we can reproduce your problem |
That is not related to opis/closure, please provide a php code that reproduces your problem when you try to serialize/unserialize something using opis/closure. |
You cannot serialize database connections in PHP. The |
|
@rowhel95 that is the stack trace only, I want to generate that trace on my computer (in other words I want to reproduce the problem), so I needed an example of PHP code. Anyway, as @msarca said, what are you trying to do is not possible in PHP. |
create a class named for example database that extends mysqli
now run this code
you will see that serializing with php works just fine but using it for closure gives exception |
I was able to reproduce this and I will provide a fix. |
This is fixed in v3.1.6. |
I have a class that extends mysqli class and those properties are defined as public but are actually read only properties so I have to put $property->setValue() and $property->getValue() inside a try and catch block for it to work.
Example:
and
The text was updated successfully, but these errors were encountered: