A faulty migration was introduced via https://github.com/impress-org/givewp/pull/5941 in 2.13.3. When the migration runs, it is intended to fix incorrect donation level meta in the form generated via onboarding. Unfortunately, the migration doesn't take into account additional meta that may be present in the array structure added later by the admin. This migration should be tweaked to handle this additional meta.
As a side note, this is why storing serialized arrays that have no corresponding object (DTO or otherwise) are dangerous. When viewing the serialized array, there's absolutely no indication as to the intended shape of the data — whether there may be more keys than present.
Acceptance Criteria
[x] Migration continues to work as intended
[x] Additional donation level meta is retained after migration
Details
A faulty migration was introduced via https://github.com/impress-org/givewp/pull/5941 in 2.13.3. When the migration runs, it is intended to fix incorrect donation level meta in the form generated via onboarding. Unfortunately, the migration doesn't take into account additional meta that may be present in the array structure added later by the admin. This migration should be tweaked to handle this additional meta.
As a side note, this is why storing serialized arrays that have no corresponding object (DTO or otherwise) are dangerous. When viewing the serialized array, there's absolutely no indication as to the intended shape of the data — whether there may be more keys than present.
Acceptance Criteria