Repository › Forums › Support › WooCommerce Extended Coupon Features PRO › provide $context parameter to get_price()
Hi, please would you consider providing a $context parameter to get_price() calls.
If no parameter is provided, the context is set ‘view’ and in view mode the price is filtered and may be changed, for example for currency conversion.
By providing a context such as ‘edit’ – even ‘coupon’ would be ok I believe – the filter is then not called and you get the raw saved price which is the safest to use for calculations.
I think that would cause issues with plugins overriding the price. Additionally, WooCommerce also uses get_price() without any context for calculations.