@@ 49-55 (lines=7) @@ | ||
46 | if (!$this->priceHasNoDate($price) && !$this->priceHasValidDate($price, new \DateTime())) { |
|
47 | return false; |
|
48 | } |
|
49 | if (is_null($country)) { |
|
50 | if ($this->priceHas($price, 'country')) { |
|
51 | return false; |
|
52 | } |
|
53 | } elseif (!$this->priceHasCountry($price, $country)) { |
|
54 | return false; |
|
55 | } |
|
56 | if (is_null($customerGroup)) { |
|
57 | if ($this->priceHas($price, 'customerGroup')) { |
|
58 | return false; |
|
@@ 63-69 (lines=7) @@ | ||
60 | } elseif (!$this->priceHasCustomerGroup($price, $customerGroup)) { |
|
61 | return false; |
|
62 | } |
|
63 | if (is_null($channel)) { |
|
64 | if ($this->priceHas($price, 'channel')) { |
|
65 | return false; |
|
66 | } |
|
67 | } elseif (!$this->priceHasChannel($price, $channel)) { |
|
68 | return false; |
|
69 | } |
|
70 | return true; |
|
71 | } |
|
72 | ); |