Wrap theme functions inside function_exists() check#1277
Wrap theme functions inside function_exists() check#1277pattonwebz wants to merge 1 commit intoAutomattic:masterfrom
Conversation
|
@davidakennedy The woocommerse.php file in the theme uses a different format for the Should I normalize all the calls to be the same syntax and if so which method would be preferable? |
|
I think current standard is to use |
|
@samikeijonen sorry, I missed the notification for this comment when you made it somehow 😕. Do you think I should go ahead and wrap the functions from |
|
As I mentioned in the issue #1116 (comment) I don't agree with making all functions pluggable. |
|
@grappler so your preference is that only a small number (those which cannot be unhooked or support removed easily) should be overloadable? I can do that if that's what is called for but you'll need to let me know what the list of functions to wrap are because people have different opinions on what is considered easily removed lol |
Yes that would be my preference.
The steps that are needed would be #1116 (comment) I am not sure how to come to a decision or who makes the final decision.. |
|
Agree completely with @grappler's take on this. |
|
Hi @pattonwebz 👋 ! Would you be still interested in updating this PR ? If not, no worries, I can pick up the work where you left off if you want, just let me know. |
|
I'd find this change helpful! |
|
@kangabell of course. I'll look it over today or tomorrow at the latest. thanks for the reminder :) |
|
I have created a new PR #1480 to adress this issue based on #1116 (comment). |
Changes proposed in this Pull Request:
This PR wraps theme functions inside of
function_exists().NOTE:
/inc/woocommerse.phpfunctions are not currently wrapped.Related issue(s):
#1116