-
Notifications
You must be signed in to change notification settings - Fork 6
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
spelling of property key gets changed #12
Comments
You can disable this behavior by setting the <table name="product">
<column name="id" type="INTEGER" primaryKey="true" autoincrement="true" />
<column name="name" type="VARCHAR" size="255" />
<behavior name="extra_properties">
<parameter name="normalize" value="false" />
</behavior>
</table> |
Thank you, I didn't know. Hard to guess from the docs, what normalize means in that context. Shouldn't there be no normalization at a default level? |
I agree with you, it's one of the "gotchas" of this behavior. But on the other hand, it allows to directly call the That's why I'm in favour of adding a note about normalization in the readme, but I'm against disabling it by default. |
I never tried, but from your explanation this code should work: $obj->setProperty('my_prop', 5);
$obj->getMyProp(); without registering the property upfront? Anyway if not, the |
"Magic calls" like At the moment, I can't see why we restrict to registered properties only, I'll investigate that in the future. Generally speaking, I think that this behavior's code needs to be cleaned and harmonized a bit. We should identify points like this one and fix them during the cleaning phase. |
I stored a property this way:
However, when I fetched them all with
$obj->getExtraProperties()
thekey
turned intoKEY
which is problematic, because the code follows with a case-sensitive spelling check and this breaks it completely.The text was updated successfully, but these errors were encountered: