You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when I have a model, let's call ist ActiveUser, which is wrapped into a proxy with on-change and with a property "editingModel" which is an ignored key, the Proxy of ActiveUser on the property "editingModel" will be revoked when ActiveUser is assigned to editingModel.
Example:
// ExpectedProxy(ActiveUser{editingModel: Proxy(ActiveUser{}),// This is an ignored key which should be able to hold the same proxyanotherProperty: ...
})// CurrentlyProxy(ActiveUser{editingModel: ActiveUser{},// Same Object as the Proxy target but not a proxy anymoreanotherProperty: ...
})
I understand why this behavior of revoking the proxy when it is assigned to itself exists, but is it necessarry to have this behavior on ignored keys or keys which are not wraped into a proxy?
Sure you want to avoid loops but I think on-change schould be able to deal with circular structures without removing proxies.
Currently this makes my bachelor thesis a little bit mor complicated. ;)
The text was updated successfully, but these errors were encountered:
Sorry I totally forgot this. I solved it now by just checking if the model in the editingModel property is the same instance as the "owner". When yes I select the model directly from the store and otherwise I choose the editingModel.
Assigning the unproxied model is not an option because I have to check for changes.
Btw. Maybe I forgot to mention that the model instance on the editingModel is exactly the same instance as the wrapping object. So ActiveUser is assigned to itself. That's why an recursion occurres and I know that you added so code to avoid that when calling the changeCallback
Hi again,
when I have a model, let's call ist ActiveUser, which is wrapped into a proxy with on-change and with a property "editingModel" which is an ignored key, the Proxy of ActiveUser on the property "editingModel" will be revoked when ActiveUser is assigned to editingModel.
Example:
I understand why this behavior of revoking the proxy when it is assigned to itself exists, but is it necessarry to have this behavior on ignored keys or keys which are not wraped into a proxy?
Sure you want to avoid loops but I think on-change schould be able to deal with circular structures without removing proxies.
Currently this makes my bachelor thesis a little bit mor complicated. ;)
The text was updated successfully, but these errors were encountered: