Skip to content

fixed bug where migrate db tried to create a new instance of an object w...#43

Open
mnelson4 wants to merge 1 commit intodeliciousbrains:masterfrom
mnelson4:master
Open

fixed bug where migrate db tried to create a new instance of an object w...#43
mnelson4 wants to merge 1 commit intodeliciousbrains:masterfrom
mnelson4:master

Conversation

@mnelson4
Copy link

...hich MIGHT have a PRIVATE CONSTRUCTOR.
I'm submitting this pull request because when we used wp-migrate-db with Event Espresso 4 (eventespresso.com), it gave us a fatal error because we're serializing objects to the database (specifically, as transients) which have a PRIVATE CONSTRUCTOR, because we're using them as singletons. (Eg, we have a class called EE_Cart, whose constructor is private, and on which you instead use a static function called instance() to get an instance of the object (and that function can call EE_Cart's constructor if it chooses)).
Was there some special reason why you needed to create a separate object and modify it, instead of just modifying the object you unserialized?
Anyways, with this change, I was succesfully able to run migrate-db with Event Espresso 4's data. Please let us know your thoughts on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant