src/PhpSpreadsheet/Calculation/MathTrig.php 1 location
|
@@ 915-917 (lines=3) @@
|
912 |
|
{ |
913 |
|
$aValue = Functions::flattenSingleValue($aValue); |
914 |
|
$style = (is_null($style)) ? 0 : (integer) Functions::flattenSingleValue($style); |
915 |
|
if ((!is_numeric($aValue)) || ($aValue < 0) || ($aValue >= 4000)) { |
916 |
|
return Functions::VALUE(); |
917 |
|
} |
918 |
|
$aValue = (integer) $aValue; |
919 |
|
if ($aValue == 0) { |
920 |
|
return ''; |
src/PhpSpreadsheet/Calculation/DateTime.php 1 location
|
@@ 1237-1241 (lines=5) @@
|
1234 |
|
$dateValue = Functions::flattenSingleValue($dateValue); |
1235 |
|
$method = Functions::flattenSingleValue($method); |
1236 |
|
|
1237 |
|
if (!is_numeric($method)) { |
1238 |
|
return Functions::VALUE(); |
1239 |
|
} elseif (($method < 1) || ($method > 2)) { |
1240 |
|
return Functions::NAN(); |
1241 |
|
} |
1242 |
|
$method = floor($method); |
1243 |
|
|
1244 |
|
if ($dateValue === null) { |