This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Plugin Name: Disable WooCommerce coming soon mode | |
* Author: Adrian Duffell | |
* Description: Automatically disables coming soon mode in WooCommerce. | |
* Version: 1.0.0 | |
*/ | |
add_filter('pre_option_woocommerce_coming_soon', 'opt_out_woocommerce_coming_soon'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Plugin Name: WooCommerce usage tracking opt-out | |
* Author: Adrian Duffell | |
* Description: Automatically opts-out of usage tracking in WooCommerce. https://woocommerce.com/usage-tracking/ | |
* Version: 1.0.0 | |
*/ | |
add_filter('pre_option_woocommerce_allow_tracking', 'opt_out_woocommerce_tracking'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( ‘woocommerce_coming_soon_exclude’, function( $is_excluded ) { | |
$current_user = wp_get_current_user(); | |
$role_to_exclude = ‘name_of_role’; | |
if ( in_array( $role_to_exclude, (array) $current_user->roles ) ) { | |
return true; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Plugin Name: CYS hotfix for removing wpcom elements from dynamic image | |
* Author: Adrian Duffell | |
* Description: Hotfix until the following PR is deployed on Woo Express https://github.com/Automattic/wc-calypso-bridge/pull/1344/f | |
* Version: 1.0.1 | |
*/ | |
add_action( 'wp_head', 'possibly_remove_wpcom_ui_elements' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Plugin Name: CYS hotfix for conflict with wpcom.editor | |
* Author: Adrian Duffell | |
* Description: Hotfix until the following PR is deployed on Woo Express https://github.com/Automattic/wc-calypso-bridge/pull/1337 | |
* Version: 1.0.0 | |
*/ | |
add_action( 'admin_print_scripts', function() { | |
if ( isset( $_GET['path'] ) && str_contains( wp_unslash( $_GET['path'] ), '/customize-store/' ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: WooCommerce Calypso Bridge Helper | |
* Plugin URI: https://woocommerce.com | |
* Description: Utility to assist testing wc-calypso-bridge locally | |
* Author: WooCommerce | |
* Version: 0.1 | |
*/ | |
class Atomic_Plan_Manager { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: WooCommerce Enable COT | |
* Description: Adds the code to enable Custom Order Tables. | |
* Version: 0.0.1 | |
*/ | |
function enable_cot(){ | |
$order_controller = wc_get_container() | |
->get('Automattic\WooCommerce\Internal\DataStores\Orders\CustomOrdersTableController'); |