Skip to content

Commit

Permalink
moved initAdminFunctions
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitcbr committed May 28, 2024
1 parent 1d7fccb commit 4b3ef7e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 0 additions & 6 deletions includes/api/api.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,12 +179,6 @@ function initCartCommon()

}

function initAdminFunctions()
{
if (defined('WC_ABSPATH')) {
include_once WC_ABSPATH . 'includes/admin/wc-admin-functions.php';
}
}

add_action('setup_extra_setting_fields', 'addMagicCheckoutSettingFields');

Expand Down
7 changes: 7 additions & 0 deletions includes/razorpay-affordability-widget.php
Original file line number Diff line number Diff line change
Expand Up @@ -510,6 +510,13 @@ function getAffordabilityWidgetSettings()
return apply_filters('wc_affordability_widget_settings', $settings);
}

function initAdminFunctions()
{
if (defined('WC_ABSPATH')) {
include_once WC_ABSPATH . 'includes/admin/wc-admin-functions.php';
}
}

function displayAffordabilityWidgetSettings()
{
initAdminFunctions();
Expand Down

0 comments on commit 4b3ef7e

Please sign in to comment.