PluginProbe
TablePress – Tables in WordPress made easy / 3.4
TablePress – Tables in WordPress made easy v3.4
3.4 3.3.4 3.3.3 3.3.2 3.3.1 trunk 1.12 1.14 1.9.2 2.0.4 2.1.7 2.1.8 2.2 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.3 2.3.1 2.3.2 2.4 2.4.1 2.4.2 2.4.3 All 45 releases
← All changes | libraries/vendor/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/TextValue.php +14 -1 3.3.1 → 3.4 View file →
@@ -53,9 +53,10 @@
53 53
54 54 protected function operator(string $operator): void
55 55 {
56 56 if (!isset(self::OPERATORS[$operator])) {
57 - throw new Exception('Invalid Operator for Text Value CF Rule Wizard');
57 + // should not happen - compareKeys confirms
58 + throw new Exception('Invalid Operator for Text Value CF Rule Wizard'); // @codeCoverageIgnore
58 59 }
59 60
60 61 $this->operator = $operator;
61 62 }
@@ -159,6 +160,18 @@
159 160 $this->operand($arg0, $arg1);
160 161 }
161 162
162 163 return $this;
164 + }
165 +
166 + /** @internal */
167 + public static function compareKeys(): bool
168 + {
169 + $retVal = true;
170 + $array = array_keys(self::OPERATORS);
171 + foreach ($array as $value) {
172 + $retVal = $retVal && in_array($value, self::MAGIC_OPERATIONS, true);
173 + }
174 +
175 + return $retVal;
163 176 }
164 177 }