Version 4.7.6

This commit is contained in:
Neo committed 2025-12-19 16:05:19 -08:00
1 parent 8ba7d43898
commit 7b7404e741
1085 files changed
+30590 -7837

No files matched your search

@@ -85,7 +85,7 @@ class _shippingrates extends \IPS\Node\Controller
$allAreZero = TRUE;
foreach ( $rate['min'] as $val )
{
if ( $val !== 0 )
if ( (int) $val !== 0 )
{
$allAreZero = FALSE;
}
@@ -96,7 +96,7 @@ class _shippingrates extends \IPS\Node\Controller
$haveNoLowerLimit = TRUE;
}
}
elseif ( $rate['min'] === 0 )
elseif ( (int) $rate['min'] === 0 )
{
$haveNoLowerLimit = TRUE;
}
@@ -113,13 +113,13 @@ class _shippingrates extends \IPS\Node\Controller
{
foreach ( $lastUpper as $k => $v )
{
if ( \strval( $rate['min'][ $k ] - $v ) > 0.01 ) # @note: We use strval() here to prevent PHP from applying a precision to the float, inadvertently causing this to return TRUE
if ( \strval( $rate['min'][ $k ] - $v ) >= 0.02 ) # @note: We use strval() here to prevent PHP from applying a precision to the float, inadvertently causing this to return TRUE
{
$consecutive = FALSE;
}
}
}
elseif ( \strval( $rate['min'] - $lastUpper ) > 0.01 ) # @note: We use strval() here to prevent PHP from applying a precision to the float, inadvertently causing this to return TRUE
elseif ( \strval( $rate['min'] - $lastUpper ) >= 0.02 ) # @note: We use strval() here to prevent PHP from applying a precision to the float, inadvertently causing this to return TRUE
{
$consecutive = FALSE;
}