-
Notifications
You must be signed in to change notification settings - Fork 217
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
WPSC_Duplicate_Product Class #1942
WPSC_Duplicate_Product Class #1942
Conversation
…ent ID, not false.
…low for copying of meta data etc to an existing product.
Love the idea! Looks really good so far! Do you want to properly deprecate the old procedural functions in another PR, or just make that commit to this branch? (Also, a few super minor scrutinizer issues). |
I'll build on this PR and check those issues :) |
…ate_Product class.
…ted duplication functions.
Should I move the deprecated functions to https://github.com/wp-e-commerce/WP-e-Commerce/blob/master/wpsc-core/wpsc-deprecated.php ? |
Yep! |
Scrutinizer came up with a few minor issues saying "Blank line found after control structure". Are we not supposed to a line break after an if statement if it makes it more readable? Also it's suggesting for docs to "Consider making the return type a bit more specific; maybe use integer." when it can actual return |
I think we can fix the control structure spacing (not sure where that standard comes from, but it seems to be inline with core). The integer docs issue - I'd ignore that. |
WPSC_Duplicate_Product Class
Changes Unknown when pulling 6d6d8c3 on benhuson:Duplicate_Product into ** on wp-e-commerce:master**. |
@JustinSainton After doing all the recent updates to the product duplication functionality, I thought It might be better suited to component-ize it into a class.
No-body should really be using the those functions but I've make it back-compatible with the existing functions which we can deprecate if we commit this - happy to add in the deprecated function calls.
What do you think?