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
Removing the columnMap from the second parameter fixes the issue. That would be the expected behavior as there is no need to re-translate keys after getting old data and then resetting. Otherwise, there is an issue somewhere in the setting of snapshots with column maps.
The text was updated successfully, but these errors were encountered:
virgofx
changed the title
SoftDelete Behavior Breaks with Mapped Properties and Snapshots
Delete Model with SoftDelete Behavior Breaks with Mapped Properties and Snapshots
Feb 19, 2018
Deleting a model that is using the SoftDelete trait with snapshots results in an error:
Column 'firstCamelCasedColumn' doesn't make part of the column map
The problem is with the
columnMap
parameters passed into the setSnapshotData() and setOldSnapshotData().https://github.com/phalcon/cphalcon/blob/master/phalcon/mvc/model/behavior/softdelete.zep#L102-L103
Removing the columnMap from the second parameter fixes the issue. That would be the expected behavior as there is no need to re-translate keys after getting old data and then resetting. Otherwise, there is an issue somewhere in the setting of snapshots with column maps.
/cc @Jurigag
Details
The text was updated successfully, but these errors were encountered: