Check for country first for better performance.

This commit is contained in:
Narek Zakarian 2022-08-17 19:08:18 +04:00
parent 9ea71be37b
commit 4e8379af02

View file

@ -104,7 +104,7 @@ class PayUponInvoiceHelper {
* @return bool
*/
public function is_pui_ready_in_admin(): bool {
if ( $this->pui_product_status->pui_is_active() && $this->shop_country === 'DE' ) {
if ( $this->shop_country === 'DE' && $this->pui_product_status->pui_is_active() ) {
return true;
}